- add sources.
[platform/framework/web/crosswalk.git] / src / chrome / test / data / extensions / api_test / file_system / is_writable_file_entry / test.js
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 chrome.test.runTests([
6   function isNotWritableEntry() {
7     chrome.fileSystem.chooseEntry(chrome.test.callbackPass(function(entry) {
8       chrome.test.assertEq('writable.txt', entry.name);
9       // The file should not be writable, since we do not have the
10       // fileSystem.write permission.
11       chrome.fileSystem.isWritableEntry(entry, chrome.test.callbackPass(
12           function(isWritable) {
13         chrome.test.assertFalse(isWritable);
14       }));
15     }));
16   }
17 ]);