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

Unified Diff: chrome/test/data/extensions/api_test/cloud_print_private/enable_chrome_connector/cloud_print_success_tests.js

Issue 11037005: New Cloud Print Private API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/service/service_process_prefs.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/extensions/api_test/cloud_print_private/enable_chrome_connector/cloud_print_success_tests.js
diff --git a/chrome/test/data/extensions/api_test/cloud_print_private/enable_chrome_connector/cloud_print_success_tests.js b/chrome/test/data/extensions/api_test/cloud_print_private/enable_chrome_connector/cloud_print_success_tests.js
index 02f69e89a1460f947a9494844cbcdfbba640718e..0178832fd6804f72fc60fb9c454309b0dd6de975 100644
--- a/chrome/test/data/extensions/api_test/cloud_print_private/enable_chrome_connector/cloud_print_success_tests.js
+++ b/chrome/test/data/extensions/api_test/cloud_print_private/enable_chrome_connector/cloud_print_success_tests.js
@@ -3,18 +3,27 @@
// found in the LICENSE file.
var tests = [
- function successfulSetCreds() {
+ function successfulSetupConnector() {
var userEmail = 'foo@gmail.com';
var robotEmail = 'foorobot@googleusercontent.com';
var credentials = '1/23546efa54';
- chrome.cloudPrintPrivate.setCredentials(
- userEmail, robotEmail, credentials,
+ chrome.cloudPrintPrivate.setupConnector(
+ userEmail, robotEmail, credentials, true, ['printer1', 'printer2']);
+ chrome.test.succeed();
+ },
+ function getHostName() {
+ chrome.cloudPrintPrivate.getHostName(
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.assertEq("TestHostName", result);
+ }));
+ },
+ function getPrinters() {
+ chrome.cloudPrintPrivate.getPrinters(
+ chrome.test.callbackPass(function(result) {
+ chrome.test.assertNoLastError();
+ chrome.test.assertEq(result, ['printer1', 'printer2']);
+ }));
}
];
« no previous file with comments | « chrome/service/service_process_prefs.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698