Niedzielski has uploaded a new change for review.
https://gerrit.wikimedia.org/r/325698
Change subject: Chore: limit ESlint suppression
......................................................................
Chore: limit ESlint suppression
find test -iname \*.js|
xargs -rd\\n sed -ri '/no-invalid-this/d; s%this\.timeout.*%\0 //
eslint-disable-line no-invalid-this%'
Change-Id: I0ed0302ec4b50b3c5a1ac335a1259cb5030c6c2e
---
M test/features/announcements/announcements.js
M test/features/app/app.js
M test/features/app/spec.js
M test/features/definition/definition.js
M test/features/featured-image/pagecontent.js
M test/features/featured/pagecontent.js
M test/features/info/info.js
M test/features/media/pagecontent.js
M test/features/mobile-sections-lead/pagecontent.js
M test/features/mobile-sections-remaining/pagecontent.js
M test/features/mobile-sections/pagecontent-v2.js
M test/features/mobile-sections/pagecontent.js
M test/features/mobile-text/pagecontent.js
M test/features/most-read/most-read.js
M test/features/news/news.js
M test/features/random/summary.js
M test/features/random/title.js
M test/lib/anchorencode/anchorencode-test.js
M test/lib/api-util/api-util-test.js
M test/lib/parsoid/parsoid-access-test.js
20 files changed, 20 insertions(+), 40 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/mobileapps
refs/changes/98/325698/1
diff --git a/test/features/announcements/announcements.js
b/test/features/announcements/announcements.js
index 002e346..e0fc042 100644
--- a/test/features/announcements/announcements.js
+++ b/test/features/announcements/announcements.js
@@ -9,8 +9,7 @@
describe('announcements', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/app/app.js b/test/features/app/app.js
index 410a76b..ab2ee46 100644
--- a/test/features/app/app.js
+++ b/test/features/app/app.js
@@ -10,8 +10,7 @@
describe('express app', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/app/spec.js b/test/features/app/spec.js
index 559e574..8998723 100644
--- a/test/features/app/spec.js
+++ b/test/features/app/spec.js
@@ -239,8 +239,7 @@
// default params, if given
let defParams = spec['x-default-params'] || {};
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => {
return server.start();
diff --git a/test/features/definition/definition.js
b/test/features/definition/definition.js
index 84e2819..1dff3d1 100644
--- a/test/features/definition/definition.js
+++ b/test/features/definition/definition.js
@@ -9,8 +9,7 @@
describe('definition', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/featured-image/pagecontent.js
b/test/features/featured-image/pagecontent.js
index acf70fc..3cede14 100644
--- a/test/features/featured-image/pagecontent.js
+++ b/test/features/featured-image/pagecontent.js
@@ -9,8 +9,7 @@
describe('featured-image', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/featured/pagecontent.js
b/test/features/featured/pagecontent.js
index 6a65a5c..af7229c 100644
--- a/test/features/featured/pagecontent.js
+++ b/test/features/featured/pagecontent.js
@@ -19,8 +19,7 @@
describe('featured', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/info/info.js b/test/features/info/info.js
index 7c00e10..869d521 100644
--- a/test/features/info/info.js
+++ b/test/features/info/info.js
@@ -10,8 +10,7 @@
describe('service information', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/media/pagecontent.js
b/test/features/media/pagecontent.js
index 567dccc..1a77949 100644
--- a/test/features/media/pagecontent.js
+++ b/test/features/media/pagecontent.js
@@ -9,8 +9,7 @@
describe('media', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/mobile-sections-lead/pagecontent.js
b/test/features/mobile-sections-lead/pagecontent.js
index 5b41378..ec2056e 100644
--- a/test/features/mobile-sections-lead/pagecontent.js
+++ b/test/features/mobile-sections-lead/pagecontent.js
@@ -9,8 +9,7 @@
describe('mobile-sections-lead', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/mobile-sections-remaining/pagecontent.js
b/test/features/mobile-sections-remaining/pagecontent.js
index 51994a8..241b0c8 100644
--- a/test/features/mobile-sections-remaining/pagecontent.js
+++ b/test/features/mobile-sections-remaining/pagecontent.js
@@ -7,8 +7,7 @@
describe('mobile-sections-remaining', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/mobile-sections/pagecontent-v2.js
b/test/features/mobile-sections/pagecontent-v2.js
index bc7bbf4..f4b03d6 100644
--- a/test/features/mobile-sections/pagecontent-v2.js
+++ b/test/features/mobile-sections/pagecontent-v2.js
@@ -8,8 +8,7 @@
describe('mobile-sections-v2', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/mobile-sections/pagecontent.js
b/test/features/mobile-sections/pagecontent.js
index 7aace6a..a9d2444 100644
--- a/test/features/mobile-sections/pagecontent.js
+++ b/test/features/mobile-sections/pagecontent.js
@@ -9,8 +9,7 @@
describe('mobile-sections', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/mobile-text/pagecontent.js
b/test/features/mobile-text/pagecontent.js
index 906d29f..1347fd7 100644
--- a/test/features/mobile-text/pagecontent.js
+++ b/test/features/mobile-text/pagecontent.js
@@ -9,8 +9,7 @@
describe('mobile-text', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/most-read/most-read.js
b/test/features/most-read/most-read.js
index 0699276..959f4d8 100644
--- a/test/features/most-read/most-read.js
+++ b/test/features/most-read/most-read.js
@@ -22,8 +22,7 @@
describe('most-read articles', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/news/news.js b/test/features/news/news.js
index fd22ca0..5e6a9c5 100644
--- a/test/features/news/news.js
+++ b/test/features/news/news.js
@@ -47,8 +47,7 @@
describe('in the news', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/random/summary.js b/test/features/random/summary.js
index 2347809..6b3361f 100644
--- a/test/features/random/summary.js
+++ b/test/features/random/summary.js
@@ -9,8 +9,7 @@
describe('random/summary', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/features/random/title.js b/test/features/random/title.js
index c478c7f..fe15684 100644
--- a/test/features/random/title.js
+++ b/test/features/random/title.js
@@ -11,8 +11,7 @@
describe('random/title', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
before(() => { return server.start(); });
diff --git a/test/lib/anchorencode/anchorencode-test.js
b/test/lib/anchorencode/anchorencode-test.js
index f4b7132..4b18c31 100644
--- a/test/lib/anchorencode/anchorencode-test.js
+++ b/test/lib/anchorencode/anchorencode-test.js
@@ -7,8 +7,7 @@
describe('lib:anchorencode', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
it('anchorencode(empty) should return an empty string', () => {
assert.deepEqual(a.anchorencode(''), '');
diff --git a/test/lib/api-util/api-util-test.js
b/test/lib/api-util/api-util-test.js
index 6b91152..b5f6333 100644
--- a/test/lib/api-util/api-util-test.js
+++ b/test/lib/api-util/api-util-test.js
@@ -15,8 +15,7 @@
describe('lib:apiUtil', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
it('checkForQueryPagesInResponse should return 504 when query.pages are
absent', () => {
return preq.post({
diff --git a/test/lib/parsoid/parsoid-access-test.js
b/test/lib/parsoid/parsoid-access-test.js
index e9a8be7..fab5946 100644
--- a/test/lib/parsoid/parsoid-access-test.js
+++ b/test/lib/parsoid/parsoid-access-test.js
@@ -10,8 +10,7 @@
describe('lib:parsoid', function() {
- /* eslint no-invalid-this: "off" */
- this.timeout(20000);
+ this.timeout(20000); // eslint-disable-line no-invalid-this
function assertSection0(sections) {
assert.deepEqual(sections[0].id, 0);
--
To view, visit https://gerrit.wikimedia.org/r/325698
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I0ed0302ec4b50b3c5a1ac335a1259cb5030c6c2e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/mobileapps
Gerrit-Branch: master
Gerrit-Owner: Niedzielski <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits