Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(482)

Side by Side Diff: extensions/test/data/api_test_base_unittest.js

Issue 2409723002: Remove chrome.test.runWithNativesEnabled (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 test = require('test').binding; 5 var test = require('test').binding;
6 var unittestBindings = require('test_environment_specific_bindings'); 6 var unittestBindings = require('test_environment_specific_bindings');
7 7
8 unittestBindings.exportTests([ 8 unittestBindings.exportTests([
9 function testEnvironment() { 9 function testEnvironment() {
10 test.assertTrue(!!$Array); 10 test.assertTrue(!!$Array);
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 test.assertTrue(!!frameInterfaces.getInterface); 48 test.assertTrue(!!frameInterfaces.getInterface);
49 })); 49 }));
50 }, 50 },
51 function testTestBindings() { 51 function testTestBindings() {
52 var counter = 0; 52 var counter = 0;
53 function increment() { 53 function increment() {
54 counter++; 54 counter++;
55 } 55 }
56 test.runWithUserGesture(increment); 56 test.runWithUserGesture(increment);
57 test.runWithoutUserGesture(increment); 57 test.runWithoutUserGesture(increment);
58 test.runWithNativesEnabled(increment); 58 test.assertEq(2, counter);
59 test.assertEq(3, counter);
60 test.assertFalse(test.isProcessingUserGesture()); 59 test.assertFalse(test.isProcessingUserGesture());
61 test.assertTrue(!!test.getApiFeatures()); 60 test.assertTrue(!!test.getApiFeatures());
62 test.assertEq(0, test.getApiDefinitions().length); 61 test.assertEq(0, test.getApiDefinitions().length);
63 test.succeed(); 62 test.succeed();
64 } 63 }
65 ], test.runTests, exports); 64 ], test.runTests, exports);
OLDNEW
« no previous file with comments | « extensions/renderer/v8_context_native_handler.cc ('k') | ui/file_manager/externs/chrome_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698