These are chat archives for angular/material

Jul 2017
Douglas Webster
Jul 16 2017 13:11
I forgot to send the event to the form! The updated test, with a slight modification so it uses async instead of fakeAsync and a bit of tidying up is:
  it('should enable the login button when a valid username and password are entered', async(() => {
    const loginBtn = overlayContainerElement.querySelector('button[md-raised-button]') as HTMLButtonElement;
    const nameInput = overlayContainerElement.querySelector('input[formcontrolname="name"]') as HTMLInputElement;
    const passwordInput = overlayContainerElement.querySelector('input[formcontrolname="password"]') as HTMLInputElement;
    nameInput.value = 'ABC';
    nameInput.dispatchEvent(new Event('input'));   // dispatch the change so the form knows to update
    passwordInput.value = '12345678';
    passwordInput.dispatchEvent(new Event('input'));  // ditto

    viewContainerFixture.whenStable().then(() => {
      expect(loginBtn.getAttribute('ng-reflect-disabled')).toBe('false', 'Login button disabled should now be false');
Carlos Eduardo
Jul 16 2017 21:30
why footer positions is 0 left ?