Fixed members acceptance test

- The `await wait()` worked in combination with correct assertions
This commit is contained in:
Nazar Gargol 2019-12-03 16:05:56 +07:00
parent 4bd4825902
commit 02fe1591e5

View File

@ -155,20 +155,12 @@ describe('Acceptance: Members', function () {
await click('[data-test-button="save"]');
// extra timeout needed for FF on Linux - sometimes it doesn't update
// quick enough, especially on Travis, and an extra wait() call
// doesn't help
await timeout(200);
await wait();
expect(find('.gh-member-basic-settings-form input[name="name"]').value, 'name has been preserved')
.to.equal('New Name');
// disables email field after member has been created
// TODO: the commented out case should be valid, but it fails when run from headless
// expect(find('.gh-member-basic-settings-form input[name="email-disabled"]').disabled, 'makes sure email is disabled')
// .to.equal(true);
expect(find('.gh-member-basic-settings-form input[name="email"]').value, 'name has been preserved')
.to.equal('example@domain.com');
expect(find('.gh-member-basic-settings-form input[name="email-disabled"]').disabled, 'makes sure email is disabled')
.to.equal(true);
});
});
});