mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-22 00:16:15 -04:00
lint: Fix bugs and style issues introduced in PR #4718
This fixes issues introduced in commit
f8a19c4527
.
This commit is contained in:
parent
0ff8274d2e
commit
294f2a251f
6 changed files with 165 additions and 179 deletions
|
@ -1,25 +1,24 @@
|
|||
'use strict';
|
||||
|
||||
describe('scrolls to line', function () {
|
||||
// create a new pad with URL hash set before each test run
|
||||
before(async function () {
|
||||
this.timeout(60000);
|
||||
await new Promise((resolve, reject) => helper.newPad({
|
||||
cb: (err) => {
|
||||
if (err != null) return reject(err);
|
||||
resolve();
|
||||
},
|
||||
hash: 'L4',
|
||||
}));
|
||||
});
|
||||
describe('scrollTo.js', function () {
|
||||
describe('scrolls to line', function () {
|
||||
// create a new pad with URL hash set before each test run
|
||||
before(async function () {
|
||||
this.timeout(60000);
|
||||
await new Promise((resolve, reject) => helper.newPad({
|
||||
cb: (err) => (err != null) ? reject(err) : resolve(),
|
||||
hash: 'L4',
|
||||
}));
|
||||
});
|
||||
|
||||
it('Scrolls down to Line 4', async function () {
|
||||
this.timeout(10000);
|
||||
const chrome$ = helper.padChrome$;
|
||||
await helper.waitForPromise(() => {
|
||||
const topOffset = parseInt(chrome$('iframe').first('iframe')
|
||||
.contents().find('#outerdocbody').css('top'));
|
||||
return (topOffset >= 100);
|
||||
it('Scrolls down to Line 4', async function () {
|
||||
this.timeout(10000);
|
||||
const chrome$ = helper.padChrome$;
|
||||
await helper.waitForPromise(() => {
|
||||
const topOffset = parseInt(chrome$('iframe').first('iframe')
|
||||
.contents().find('#outerdocbody').css('top'));
|
||||
return (topOffset >= 100);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -28,10 +27,7 @@ describe('scrolls to line', function () {
|
|||
before(async function () {
|
||||
this.timeout(60000);
|
||||
await new Promise((resolve, reject) => helper.newPad({
|
||||
cb: (err) => {
|
||||
if (err != null) return reject(err);
|
||||
resolve();
|
||||
},
|
||||
cb: (err) => (err != null) ? reject(err) : resolve(),
|
||||
hash: '#DEEZ123123NUTS',
|
||||
}));
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue