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

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

Issue 450383003: Hangout remote desktop part II - background.html and AppLauncher (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address 2nd round feedbacks Created 6 years, 4 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/manifest.json.jinja2 ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/webapp/unittests/base_unittest.js
diff --git a/remoting/webapp/unittests/base_unittest.js b/remoting/webapp/unittests/base_unittest.js
index d021a809b20a35d2eceae7700c51d6ff1dcb97d8..17a1903b6550409959dd3eaaba456da4267d4720 100644
--- a/remoting/webapp/unittests/base_unittest.js
+++ b/remoting/webapp/unittests/base_unittest.js
@@ -56,6 +56,25 @@ test('dispose(obj) should not crash if |obj| is null',
base.dispose(null);
});
+test('urljoin(url, opt_param) should return url if |opt_param| is missing',
+ function() {
+ QUnit.equal(
+ base.urlJoin('http://www.chromium.org'), 'http://www.chromium.org');
+});
+
+test('urljoin(url, opt_param) should urlencode |opt_param|',
+ function() {
+ var result = base.urlJoin('http://www.chromium.org', {
+ a: 'a',
+ foo: 'foo',
+ escapist: ':/?#[]@$&+,;='
+ });
+ QUnit.equal(
+ result,
+ 'http://www.chromium.org?a=a&foo=foo' +
+ '&escapist=%3A%2F%3F%23%5B%5D%40%24%26%2B%2C%3B%3D');
+});
+
QUnit.asyncTest('Promise.sleep(delay) should fulfill the promise after |delay|',
function() {
var isCalled = false;
« no previous file with comments | « remoting/webapp/manifest.json.jinja2 ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698