##// END OF EJS Templates
test unicode path in dashboard_nav
MinRK -
Show More
@@ -18,9 +18,12 b' casper.test_items = function (baseUrl) {'
18 18 if (!item.label.match('.ipynb$')) {
19 19 var followed_url = baseUrl+item.link;
20 20 if (!followed_url.match('/\.\.$')) {
21 casper.thenOpen(baseUrl+item.link, function () {
21 casper.thenOpen(followed_url, function () {
22 22 casper.wait_for_dashboard();
23 this.test.assertEquals(this.getCurrentUrl(), followed_url, 'Testing dashboard link: '+followed_url);
23 // getCurrentUrl is with host, and url-decoded,
24 // but item.link is without host, and url-encoded
25 var expected = baseUrl + decodeURIComponent(item.link);
26 this.test.assertEquals(this.getCurrentUrl(), expected, 'Testing dashboard link: ' + expected);
24 27 casper.test_items(baseUrl);
25 28 this.back();
26 29 });
@@ -31,7 +34,7 b' casper.test_items = function (baseUrl) {'
31 34 }
32 35
33 36 casper.dashboard_test(function () {
34 baseUrl = this.get_notebook_server()
37 baseUrl = this.get_notebook_server();
35 38 casper.test_items(baseUrl);
36 39 })
37 40
@@ -181,8 +181,8 b' class JSController(TestController):'
181 181 self.ipydir = TemporaryDirectory()
182 182 self.nbdir = TemporaryDirectory()
183 183 print("Running notebook tests in directory: %r" % self.nbdir.name)
184 os.makedirs(os.path.join(self.nbdir.name, os.path.join('subdir1', 'subdir1a')))
185 os.makedirs(os.path.join(self.nbdir.name, os.path.join('subdir2', 'subdir2a')))
184 os.makedirs(os.path.join(self.nbdir.name, os.path.join(u'subir1', u'sub ∂ir 1a')))
185 os.makedirs(os.path.join(self.nbdir.name, os.path.join(u'subir2', u'sub ∂ir 1b')))
186 186 self.dirs.append(self.ipydir)
187 187 self.dirs.append(self.nbdir)
188 188
General Comments 0
You need to be logged in to leave comments. Login now