Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 var callbackPass = chrome.test.callbackPass; | 5 var callbackPass = chrome.test.callbackPass; |
| 6 var callbackFail = chrome.test.callbackFail; | 6 var callbackFail = chrome.test.callbackFail; |
| 7 var defaultFuzzFactor = 1; | 7 var defaultFuzzFactor = 1; |
| 8 | 8 |
| 9 function assertFuzzyEq(expected, actual, fuzzFactor, message) { | 9 function assertFuzzyEq(expected, actual, fuzzFactor, message) { |
| 10 if (!message) { | 10 if (!message) { |
| (...skipping 1334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1345 chrome.app.window.create('test.html', { | 1345 chrome.app.window.create('test.html', { |
| 1346 frame: { | 1346 frame: { |
| 1347 color: 'DontWorryBeHappy' | 1347 color: 'DontWorryBeHappy' |
| 1348 } | 1348 } |
| 1349 }, | 1349 }, |
| 1350 callbackFail('The color specification could not be parsed.')); | 1350 callbackFail('The color specification could not be parsed.')); |
| 1351 } | 1351 } |
| 1352 ]); | 1352 ]); |
| 1353 } | 1353 } |
| 1354 | 1354 |
| 1355 function testVisibleOnAllWorkspaces() { | |
| 1356 chrome.test.runTests([ | |
| 1357 function setAndUnsetVisibleOnAllWorkspaces() { | |
| 1358 chrome.app.window.create('test.html', { | |
| 1359 visibleOnAllWorkspaces: true | |
| 1360 }, callbackPass(function(win) { | |
| 1361 win.setVisibleOnAllWorkspaces(false); | |
| 1362 win.setVisibleOnAllWorkspaces(true); | |
| 1363 chrome.test.sendMessage( | |
| 1364 'WaitForRoundTrip', callbackPass(function(reply) {})); | |
|
benwells
2014/08/20 05:02:08
Does this actually test anything?
jackhou1
2014/08/27 05:10:45
Nup, it's just a smoke test, like testBadging().
| |
| 1365 })); | |
| 1366 }, | |
| 1367 ]); | |
| 1368 } | |
| 1369 | |
| 1355 chrome.app.runtime.onLaunched.addListener(function() { | 1370 chrome.app.runtime.onLaunched.addListener(function() { |
| 1356 chrome.test.sendMessage('Launched', function(reply) { | 1371 chrome.test.sendMessage('Launched', function(reply) { |
| 1357 window[reply](); | 1372 window[reply](); |
| 1358 }); | 1373 }); |
| 1359 }); | 1374 }); |
| OLD | NEW |