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

Delta Between Two Patch Sets: test/all.js

Issue 29866577: Issue 6887 - add Chrome to "npm test" (Closed)
Left Patch Set: Created Sept. 1, 2018, 2:46 p.m.
Right Patch Set: Removed unused this.platform Created Sept. 1, 2018, 3:12 p.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/.eslintrc.json ('k') | test/browsers/chromium.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-present eyeo GmbH 3 * Copyright (C) 2006-present 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
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 return this.driver.wait(() => 55 return this.driver.wait(() =>
56 this.driver.getAllWindowHandles().then(handles => handles[1]) 56 this.driver.getAllWindowHandles().then(handles => handles[1])
57 ); 57 );
58 }).then(handle => 58 }).then(handle =>
59 this.driver.switchTo().window(handle) 59 this.driver.switchTo().window(handle)
60 ).then(() => 60 ).then(() =>
61 this.driver.executeScript("return location.origin;") 61 this.driver.executeScript("return location.origin;")
62 ).then(origin => 62 ).then(origin =>
63 { 63 {
64 this.origin = origin; 64 this.origin = origin;
65 this.platform = module.platform;
66 }); 65 });
67 }); 66 });
68 67
69 for (let file of glob.sync("./test/wrappers/*.js")) 68 for (let file of glob.sync("./test/wrappers/*.js"))
70 { 69 {
71 // Reload the module(s) for every browser 70 // Reload the module(s) for every browser
72 let modulePath = path.resolve(file); 71 let modulePath = path.resolve(file);
73 delete require.cache[require.resolve(modulePath)]; 72 delete require.cache[require.resolve(modulePath)];
74 require(modulePath); 73 require(modulePath);
75 } 74 }
76 75
77 after(function() 76 after(function()
78 { 77 {
79 this.driver.quit(); 78 this.driver.quit();
80 }); 79 });
81 }); 80 });
82 } 81 }
LEFTRIGHT

Powered by Google App Engine
This is Rietveld