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 // system.display api test | 5 // system.display api test |
6 // app_shell_browsertests --gtest_filter=SystemDisplayApiTest.* | 6 // extensions_browsertests --gtest_filter=SystemDisplayApiTest.* |
7 | 7 |
8 chrome.test.runTests([ | 8 chrome.test.runTests([ |
9 function testGet() { | 9 function testGet() { |
10 for(var i = 0; i < 10; ++i) { | 10 for(var i = 0; i < 10; ++i) { |
11 chrome.system.display.getInfo( | 11 chrome.system.display.getInfo( |
12 chrome.test.callbackPass(function(result) { | 12 chrome.test.callbackPass(function(result) { |
13 chrome.test.assertEq(4, result.length); | 13 chrome.test.assertEq(4, result.length); |
14 for (var i = 0; i < result.length; i++) { | 14 for (var i = 0; i < result.length; i++) { |
15 var info = result[i]; | 15 var info = result[i]; |
16 chrome.test.assertEq('' + i, info.id); | 16 chrome.test.assertEq('' + i, info.id); |
(...skipping 27 matching lines...) Expand all Loading... |
44 chrome.test.assertEq(0, info.workArea.left); | 44 chrome.test.assertEq(0, info.workArea.left); |
45 chrome.test.assertEq(0, info.workArea.top); | 45 chrome.test.assertEq(0, info.workArea.top); |
46 chrome.test.assertEq(960, info.workArea.width); | 46 chrome.test.assertEq(960, info.workArea.width); |
47 chrome.test.assertEq(720, info.workArea.height); | 47 chrome.test.assertEq(720, info.workArea.height); |
48 } | 48 } |
49 })); | 49 })); |
50 } | 50 } |
51 } | 51 } |
52 ]); | 52 ]); |
53 | 53 |
OLD | NEW |