Index: chrome/test/data/extensions/api_test/chrome_auth_private/enable_chrome_connector/cloud_print_success_tests.js |
diff --git a/chrome/test/data/extensions/api_test/chrome_auth_private/enable_chrome_connector/cloud_print_success_tests.js b/chrome/test/data/extensions/api_test/chrome_auth_private/enable_chrome_connector/cloud_print_success_tests.js |
new file mode 100644 |
index 0000000000000000000000000000000000000000..62f92239b96aa5264ba72f683190a28b27bc7c93 |
--- /dev/null |
+++ b/chrome/test/data/extensions/api_test/chrome_auth_private/enable_chrome_connector/cloud_print_success_tests.js |
@@ -0,0 +1,22 @@ |
+// Copyright (c) 2011 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+ |
+var tests = [ |
+ function successfulSetCreds() { |
+ var userEmail = 'foo@gmail.com'; |
+ var robotEmail = 'foorobot@googleusercontent.com'; |
+ var credentials = '1/23546efa54'; |
+ chrome.chromeAuthPrivate.setCloudPrintCredentials( |
+ userEmail, robotEmail, credentials, |
+ chrome.test.callbackPass(function(result) { |
+ // In test mode, we expect the API to reflect the arguments back to |
+ // us appended together. |
+ chrome.test.assertNoLastError(); |
+ chrome.test.assertEq(result, userEmail + robotEmail + credentials); |
+ })); |
+ } |
+]; |
+ |
+chrome.test.runTests(tests); |