Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Delta Between Two Patch Sets: test/subscriptionClasses.js

Issue 29375915: Issue 4878 - Start using ESLint for adblockpluscore (Closed)
Left Patch Set: Addressed Sebastian's initial feedback Created Feb. 21, 2017, 6:12 a.m.
Right Patch Set: Removed unused imports Created March 15, 2017, 3:11 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « test/stub-modules/utils.js ('k') | test/synchronizer.js » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-2016 Eyeo GmbH 3 * Copyright (C) 2006-2016 Eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details. 12 * GNU General Public License for more details.
13 * 13 *
14 * You should have received a copy of the GNU General Public License 14 * You should have received a copy of the GNU General Public License
15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>. 15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
16 */ 16 */
17 17
18 "use strict"; 18 "use strict";
19 19
20 let {createSandbox} = require("./_common"); 20 const {createSandbox} = require("./_common");
21 21
22 let Subscription = null; 22 let Subscription = null;
23 let SpecialSubscription = null; 23 let SpecialSubscription = null;
24 let DownloadableSubscription = null; 24 let DownloadableSubscription = null;
25 let RegularSubscription = null; 25 let RegularSubscription = null;
26 let ExternalSubscription = null; 26 let ExternalSubscription = null;
27 27
28 exports.setUp = function(callback) 28 exports.setUp = function(callback)
29 { 29 {
30 let sandboxedRequire = createSandbox(); 30 let sandboxedRequire = createSandbox();
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 compareSubscription(test, "http://test/default", ["url=http://test/default", " title=http://test/default"]); 74 compareSubscription(test, "http://test/default", ["url=http://test/default", " title=http://test/default"]);
75 compareSubscription( 75 compareSubscription(
76 test, "http://test/default_titled", ["url=http://test/default_titled", "titl e=test"], 76 test, "http://test/default_titled", ["url=http://test/default_titled", "titl e=test"],
77 subscription => 77 subscription =>
78 { 78 {
79 subscription.title = "test"; 79 subscription.title = "test";
80 } 80 }
81 ); 81 );
82 compareSubscription( 82 compareSubscription(
83 test, "http://test/non_default", 83 test, "http://test/non_default",
84 ["url=http://test/non_default", "title=test", "disabled=true", 84 [
85 "lastSuccess=8", "lastDownload=12", "lastCheck=16", "softExpiration=18", 85 "url=http://test/non_default", "title=test", "disabled=true",
86 "expires=20", "downloadStatus=foo", "errors=3", "version=24", 86 "lastSuccess=8", "lastDownload=12", "lastCheck=16", "softExpiration=18",
87 "requiredVersion=0.6"], 87 "expires=20", "downloadStatus=foo", "errors=3", "version=24",
88 "requiredVersion=0.6"
89 ],
88 subscription => 90 subscription =>
89 { 91 {
90 subscription.title = "test"; 92 subscription.title = "test";
91 subscription.disabled = true; 93 subscription.disabled = true;
92 subscription.lastSuccess = 8; 94 subscription.lastSuccess = 8;
93 subscription.lastDownload = 12; 95 subscription.lastDownload = 12;
94 subscription.lastCheck = 16; 96 subscription.lastCheck = 16;
95 subscription.softExpiration = 18; 97 subscription.softExpiration = 18;
96 subscription.expires = 20; 98 subscription.expires = 20;
97 subscription.downloadStatus = "foo"; 99 subscription.downloadStatus = "foo";
98 subscription.errors = 3; 100 subscription.errors = 3;
99 subscription.version = 24; 101 subscription.version = 24;
100 subscription.requiredVersion = "0.6"; 102 subscription.requiredVersion = "0.6";
101 } 103 }
102 ); 104 );
103 compareSubscription( 105 compareSubscription(
104 test, "~wl~", ["url=~wl~", "disabled=true", "title=Test group"], 106 test, "~wl~", ["url=~wl~", "disabled=true", "title=Test group"],
105 subscription => 107 subscription =>
106 { 108 {
107 subscription.title = "Test group"; 109 subscription.title = "Test group";
108 subscription.disabled = true; 110 subscription.disabled = true;
109 } 111 }
110 ); 112 );
111 113
112 test.done(); 114 test.done();
113 }; 115 };
LEFTRIGHT

Powered by Google App Engine
This is Rietveld