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

Unified Diff: extensions/test/data/api_test/display_source/api/background.js

Issue 1471243002: chrome.displaySource custom bindings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing nits Created 5 years 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 | « extensions/renderer/resources/extensions_renderer_resources.grd ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/test/data/api_test/display_source/api/background.js
diff --git a/extensions/test/data/api_test/display_source/api/background.js b/extensions/test/data/api_test/display_source/api/background.js
index a54d6b5ea05a127efd3394586798054251324678..a10efe45a629608304ac5dfbc3c55f1f7298447d 100644
--- a/extensions/test/data/api_test/display_source/api/background.js
+++ b/extensions/test/data/api_test/display_source/api/background.js
@@ -34,6 +34,25 @@ var testRequestAuthentication = function() {
chrome.displaySource.requestAuthentication(1, callback);
};
+var testStartSessionErrorReport = function() {
+ var callback = function() {
+ chrome.test.assertLastError('Invalid stream arguments');
+ chrome.test.succeed();
+ };
+ var session_info = { sinkId: 1, authenticationInfo: { method: "PBC" } };
+ chrome.displaySource.startSession(session_info, callback);
+};
+
+var testTerminateSessionErrorReport = function() {
+ var callback = function() {
+ chrome.test.assertLastError('Session not found');
+ chrome.test.succeed();
+ };
+ chrome.displaySource.terminateSession(1, callback);
+};
+
chrome.test.runTests([testGetAvailableSinks,
testOnSinksUpdated,
- testRequestAuthentication]);
+ testRequestAuthentication,
+ testStartSessionErrorReport,
+ testTerminateSessionErrorReport]);
« no previous file with comments | « extensions/renderer/resources/extensions_renderer_resources.grd ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698