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

Unified Diff: chrome/test/data/extensions/api_test/file_system/get_display_path_prettify_mac/test.js

Issue 10823157: Prettify Mac names, rewrite getDisplayPath API call to focus on $HOME (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: windows fix Created 8 years, 3 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/test/data/extensions/api_test/file_system/get_display_path_prettify_mac/test.html ('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/file_system/get_display_path_prettify_mac/test.js
diff --git a/chrome/test/data/extensions/api_test/file_system/get_display_path_prettify_mac/test.js b/chrome/test/data/extensions/api_test/file_system/get_display_path_prettify_mac/test.js
new file mode 100644
index 0000000000000000000000000000000000000000..301d1a4b3fecd2799b41dfa9f134ddc251ddbf3e
--- /dev/null
+++ b/chrome/test/data/extensions/api_test/file_system/get_display_path_prettify_mac/test.js
@@ -0,0 +1,22 @@
+
+// Copyright (c) 2012 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.
+
+chrome.test.runTests([
+ function getDisplayPath() {
+ chrome.fileSystem.chooseFile(chrome.test.callbackPass(function(entry) {
+ chrome.test.assertEq('gold.txt', entry.name);
+
+ // The on-disk path of this file ends with '/test.localized/gold.txt', so
+ // check that getDisplayPath correctly localizes the path by stripping
+ // the '.localized' suffix.
+ chrome.fileSystem.getDisplayPath(entry, chrome.test.callbackPass(
+ function(path) {
+ var suffix = '/test/gold.txt';
+ chrome.test.assertEq(suffix,
+ path.substring(path.length - suffix.length));
+ }));
+ }));
+ }
+]);
« no previous file with comments | « chrome/test/data/extensions/api_test/file_system/get_display_path_prettify_mac/test.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698