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

Unified Diff: remoting/webapp/unittests/sinon_helpers.js

Issue 959963002: [Chromoting] Enable jscompile for webapp unittests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix key tester Created 5 years, 10 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 | « remoting/webapp/unittests/mock_signal_strategy.js ('k') | remoting/webapp/unittests/test_start.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/webapp/unittests/sinon_helpers.js
diff --git a/remoting/webapp/unittests/sinon_helpers.js b/remoting/webapp/unittests/sinon_helpers.js
new file mode 100644
index 0000000000000000000000000000000000000000..763a9391f370cab96d5c1f987fa67c55ab112ba6
--- /dev/null
+++ b/remoting/webapp/unittests/sinon_helpers.js
@@ -0,0 +1,21 @@
+// Copyright 2015 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 sinonHelpers = {};
+
+sinonHelpers.reset = function() {
+
+/**
+ * @param {Object} obj
+ * @param {string} method
+ * @return {sinon.TestStub}
+ * @suppress {reportUnknownTypes}
+ */
+sinon.$setupStub = function(obj, method) {
+ sinon.stub(obj, method);
+ obj[method].$testStub = /** @type {sinon.TestStub} */ (obj[method]);
+ return obj[method].$testStub;
+};
+
+};
« no previous file with comments | « remoting/webapp/unittests/mock_signal_strategy.js ('k') | remoting/webapp/unittests/test_start.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698