mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-22 00:16:15 -04:00
tests: Refine frontend tests
* Switch from `helper.newPad()` to `helper.aNewPad()`. * Promisify. * Delete redundant logic. * Lint fixes.
This commit is contained in:
parent
3790c0e41c
commit
bbf89dfcf9
35 changed files with 697 additions and 842 deletions
|
@ -3,9 +3,9 @@
|
|||
describe('chat-load-messages', function () {
|
||||
let padName;
|
||||
|
||||
it('creates a pad', function (done) {
|
||||
padName = helper.newPad(done);
|
||||
it('creates a pad', async function () {
|
||||
this.timeout(60000);
|
||||
padName = await helper.aNewPad();
|
||||
});
|
||||
|
||||
it('adds a lot of messages', async function () {
|
||||
|
@ -26,7 +26,7 @@ describe('chat-load-messages', function () {
|
|||
chatInput.sendkeys('{enter}');
|
||||
await helper.waitForPromise(() => chatText.children('p').length === i);
|
||||
}
|
||||
await new Promise((resolve) => helper.newPad(() => resolve(), padName));
|
||||
await helper.aNewPad({id: padName});
|
||||
});
|
||||
|
||||
it('checks initial message count', function (done) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue