input_spec.js 541 B

123456789101112131415
  1. describe('angular-material input component page', function() {
  2. const EC = protractor.ExpectedConditions;
  3. it('Should change input component value', async() => {
  4. await browser.get('https://material.angular.io/components/input/examples');
  5. await browser.wait(EC.elementToBeClickable($('.mat-button-wrapper>.mat-icon')), 5000);
  6. const emailInputField = $$('.mat-form-field-infix>input').get(1);
  7. await emailInputField.sendKeys('invalid');
  8. expect($('mat-error').isPresent()).toBe(true);
  9. });
  10. });