Skip to content
Mohammad Naghavi edited this page Jun 26, 2014 · 3 revisions

Due to the nature of cordova plugins and the need for a real device to be able to test in-app purchasing, the tests for this plugin live in a sample application which can be complied and run on all of the target devices for testing this application.

In order to run tests, you have to obtain a copy of the code, change the bundle id of the app so that you can add it to your account in Google developer console or iTunes and compile it. Generally you need to go through installation and [stores setup](Stores setup) before trying the tests.

Be careful with payments as they can be real ones!

How to run tests

After you are setup and ready, the tests will run automatically when you start the applications. Some of the tests also need user interaction like going through payment or subscription. Do them ONLY if you are on a test account or if you want to test with real payments.

If everything goes well, you will have something like following pic at the end of your page:

How to disable tests

Inside the application, user may interact with the plugin manually, but in case you want to disable this automatic run of tests, comment out the following line in www\index.html:

<script type="text/javascript" src="spec/boot.js"></script>
  • Installation
  • [Stores setup](Stores setup)
  • [Purchase verification](Purchase verification)
  • [Testing plugin](Automatic tests)
  • [API documentation](API documentation)
  • Debugging

Philosophy

  • Roadmap
  • [Compatibility issues](Compatibility issues)

API

Clone this wiki locally