You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by GitBox <gi...@apache.org> on 2019/03/06 03:03:47 UTC

[GitHub] [cordova-plugin-inappbrowser] knight9999 opened a new pull request #440: Fix test spec.5 to close inappbrowser after loadstop event

knight9999 opened a new pull request #440: Fix test spec.5 to close inappbrowser after loadstop event
URL: https://github.com/apache/cordova-plugin-inappbrowser/pull/440
 
 
   ### Platforms affected
   all platforms (but test only)
   
   
   ### Motivation and Context
   
   The spec 'inappbrowser.spec.5 should support exit event' is testing exit event.
   But before this PR, `close` method may be fired before InAppBrowser open the URL.
   Then cordova-windows, the tests sometimes fails, the InAppBrowser is kept opened. 
   Then the next spec (spec.6) fails.
   ![2019-03-06 11 17 55](https://user-images.githubusercontent.com/5112183/53853014-49e1e300-4007-11e9-8a6e-35db2ed78aff.png)
   
   This PR is to fix this issue.
   
   ### Description
   
   Instead of calling `close()` method synchronously,
   I call `close()` method in callback of `loadstop` event.
   
   
   ### Testing
   With the help of cordova-mobile-spec, I confirmed all cordova-plugin-inappbrowser-tests.tests work well.
   
   ### Checklist
   
   - [x] I've run the tests to see all new and existing tests pass
   - [ ] I added automated test coverage as appropriate for this change
   - [ ] Commit is prefixed with `(platform)` if this change only applies to one platform (e.g. `(android)`)
   - [ ] If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct [keyword to close issues using keywords](https://help.github.com/articles/closing-issues-using-keywords/))
   - [ ] I've updated the documentation if necessary
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

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