You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by martincgg <gi...@git.apache.org> on 2014/06/24 12:21:43 UTC

[GitHub] cordova-mobile-spec pull request: CB-7010 (WP8) compare proper str...

GitHub user martincgg opened a pull request:

    https://github.com/apache/cordova-mobile-spec/pull/76

    CB-7010 (WP8) compare proper string for path

    In case of platformId === 'windowsphone', compare with proper string('//num 1/num 2'),
    the test fails because WP8 platform it doesn't recognize
    /num%201/num%202/.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/martincgg/cordova-mobile-spec CB-7010

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/cordova-mobile-spec/pull/76.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #76
    
----
commit b58ecf493c38a373adb70c05f685efc5b335ca99
Author: Martin Gonzalez <ma...@gmail.com>
Date:   2014-06-24T10:03:02Z

    CB-7010 (WP8) compare proper string for path
    
    In case of platformId === 'windowsphone', compare with proper string,
    the test fails because WP8 platform it doesn't recognize
    /num%201/num%202/.

----


---
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.
---

[GitHub] cordova-mobile-spec pull request: CB-7010 (WP8) compare proper str...

Posted by martincgg <gi...@git.apache.org>.
Github user martincgg commented on the pull request:

    https://github.com/apache/cordova-mobile-spec/pull/76#issuecomment-46960316
  
    Hi @purplecabbage ,
    I've been working on the File API and the mobile spec test as well, this specific PR, the native side is not returning the path with the URL-encoding as %20, I thought that it was totally acceptable if spaces were returned instead.
    Let me report some of my findings:
    
    ![file api mobilespec](https://cloud.githubusercontent.com/assets/6596402/3370432/4d0b80a6-fb90-11e3-8bcb-6cd3bda912c9.png)
    
    In the image at left is mostly after this fix: https://issues.apache.org/jira/browse/CB-6980
    in the right that was before of it. Several were failing because resolveLocalFileSystemURI it was losing information about the filesystem property.
    The first square marked on the image it belongs to 4 tests (spec 67, 68, 69 and 78) which are failing when a file is moved and the filesystem information is lost at some point, the issue related is CB-6901.
    The second square is related with support of readAsBinaryString & readAsArrayBuffer, issues CB-6988 & CB-6989, I've been working to setup those methods on the native side.
    The third square is related with the issue CB-6923 (I'm working on that one too), the native side is not able to handle the resolve navigation a parent directory using a relative path, e.g.:
    fileName = ../resolve.file.uri
    I'll continue working on those issues
    About the mobile spec conditions some of them are about join paths for Windows Phone and some others are to compare the path retrieved from the native side something like: //native instead of file://.
    Tests on Windows Phone 8 & 8.1 emulator as well as physical device, both are consistent behavior related with the mentioned issues.



---
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.
---

[GitHub] cordova-mobile-spec pull request: CB-7010 (WP8) compare proper str...

Posted by martincgg <gi...@git.apache.org>.
Github user martincgg closed the pull request at:

    https://github.com/apache/cordova-mobile-spec/pull/76


---
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.
---

[GitHub] cordova-mobile-spec pull request: CB-7010 (WP8) compare proper str...

Posted by martincgg <gi...@git.apache.org>.
Github user martincgg commented on the pull request:

    https://github.com/apache/cordova-mobile-spec/pull/76#issuecomment-47003313
  
    It's possible of course, call the decodeURIComponent in the test, I can get it done.
    Now in WP8 native side, it's possible add logic to:
    public FileEntry(string filePath, bool bIsRes=false) {}
    to return a entry file with the URI encoded, using the Uri.EscapeUriString/Uri.EscapeDataString, this will force the user to decode the path in the web side.
    Also we can use the Uri.UnescapedDataString to decode the paths in the native side.
    Any suggestions?


---
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.
---

[GitHub] cordova-mobile-spec pull request: CB-7010 (WP8) compare proper str...

Posted by purplecabbage <gi...@git.apache.org>.
Github user purplecabbage commented on the pull request:

    https://github.com/apache/cordova-mobile-spec/pull/76#issuecomment-46955345
  
    We can't add these conditional tests everywhere. We need to fix the source issue, and not just the symptom. 
    I have numerous file-api issues in-progress in jira, and I'll get to this one as well. 


---
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.
---

[GitHub] cordova-mobile-spec pull request: CB-7010 (WP8) compare proper str...

Posted by purplecabbage <gi...@git.apache.org>.
Github user purplecabbage commented on the pull request:

    https://github.com/apache/cordova-mobile-spec/pull/76#issuecomment-46996828
  
    Can we just call decodeURIComponent on the result, and compare it to the space version? Then we remove the conditional comparator.  
    Ideally, I think native should encode the result to match ios/android


---
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.
---

[GitHub] cordova-mobile-spec pull request: CB-7010 (WP8) compare proper str...

Posted by martincgg <gi...@git.apache.org>.
Github user martincgg commented on the pull request:

    https://github.com/apache/cordova-mobile-spec/pull/76#issuecomment-51419463
  
    no longer valid, closing


---
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.
---