mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-01-31 19:02:59 +01:00
tests: Add missing await
s to change_user_name.js
Also increase the timeouts.
This commit is contained in:
parent
bbf89dfcf9
commit
d15ff9ce8d
1 changed files with 12 additions and 17 deletions
|
@ -7,27 +7,22 @@ describe('change username value', function () {
|
||||||
});
|
});
|
||||||
|
|
||||||
it('Remembers the user name after a refresh', async function () {
|
it('Remembers the user name after a refresh', async function () {
|
||||||
this.timeout(1500);
|
this.timeout(10000);
|
||||||
helper.toggleUserList();
|
await helper.toggleUserList();
|
||||||
helper.setUserName('😃');
|
await helper.setUserName('😃');
|
||||||
|
// get a new pad, but don't clear the cookies
|
||||||
helper.newPad({ // get a new pad, but don't clear the cookies
|
await helper.aNewPad({clearCookies: false});
|
||||||
clearCookies: false,
|
await helper.toggleUserList();
|
||||||
cb() {
|
expect(helper.usernameField().val()).to.be('😃');
|
||||||
helper.toggleUserList();
|
|
||||||
|
|
||||||
expect(helper.usernameField().val()).to.be('😃');
|
|
||||||
},
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
|
|
||||||
it('Own user name is shown when you enter a chat', async function () {
|
it('Own user name is shown when you enter a chat', async function () {
|
||||||
this.timeout(1500);
|
this.timeout(10000);
|
||||||
helper.toggleUserList();
|
await helper.toggleUserList();
|
||||||
helper.setUserName('😃');
|
await helper.setUserName('😃');
|
||||||
|
|
||||||
helper.showChat();
|
await helper.showChat();
|
||||||
helper.sendChatMessage('O hi{enter}');
|
await helper.sendChatMessage('O hi{enter}');
|
||||||
|
|
||||||
await helper.waitForPromise(() => {
|
await helper.waitForPromise(() => {
|
||||||
// username:hours:minutes text
|
// username:hours:minutes text
|
||||||
|
|
Loading…
Reference in a new issue