cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From daserge <...@git.apache.org>
Subject [GitHub] cordova-plugin-file-transfer pull request: CB-9969 Filetransfer up...
Date Thu, 26 Nov 2015 18:29:02 GMT
Github user daserge commented on a diff in the pull request:

    https://github.com/apache/cordova-plugin-file-transfer/pull/115#discussion_r46001338
  
    --- Diff: tests/tests.js ---
    @@ -450,7 +450,7 @@ exports.defineAutoTests = function () {
                             expect(transfer.onprogress).toHaveBeenCalled();
     
                             // check that there is no file
    -                        root.getFile(localFilePath, null, unexpectedCallbacks.fileSystemWin,
done);
    +                        root.getFile(fileName, null, unexpectedCallbacks.fileSystemWin,
done);
    --- End diff --
    
    Despite the fact that [the docs](https://github.com/apache/cordova-plugin-file/blob/ab42f3e7c6c2282ac303e32260e8d68fdd2e18e3/www/DirectoryEntry.js#L98)
says it takes a relative or an absolute path (by the way I can't find any File plugin test
for an absolute path), the use of `localFilePath` (which is `file:///` on Android and `ms-appdata:///`
on Windows) causes a fail with `FileError.ENCODING_ERR = 5` instead of `FileError.NOT_FOUND_ERR
= 1`.
    Probably the absolute path should be absolute to the fs root like `/dir/file.txt` and
not a native path.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


Mime
View raw message