Skip to content

Latest commit

 

History

History
73 lines (49 loc) · 2.19 KB

DevelopmentWorkflow.md

File metadata and controls

73 lines (49 loc) · 2.19 KB

Development Workflow

Prerequisites

Develop locally

For local development we recommend using the npm commands provided in the plugin's package.json

Basically executing a bunch of commands will be enough for you to start making changes to the plugin and see them live synced in the demo. It's up to you to decide which demo to use for development - TypeScript or TypeScript + Angular.

To run and develop using TypeScript demo:

$ cd nativescript-imagepicker/src
$ npm run demo.ios
$ npm run demo.android

To run and develop using TypeScript + Angular demo:

$ cd nativescript-imagepicker/src
$ npm run demo.ng.ios
$ npm run demo.ng.android

After all the changes are done make sure to

  • test them in all the demo apps
  • run the UI tests.

For details on plugins development workflow, read NativeScript plugins documentation covering that topic.

Run UI Tests

  1. Navigate to demo/e2e

    cd demo/e2e
  2. Make sure to have an emulator set up or connect a physical Android/iOS device.

  3. Build the app for Android or iOS

    tns build android
    tns build ios
  4. Install appium globally.

    npm install -g appium
  5. Follow the instructions in the nativescript-dev-appium plugin to add an appium capability for your device inside appium.capabilities.json.

  6. Run the automated tests. The value of the runType argument should match the name of the capability that you just added.

    npm run e2e -- --runType capabilityName

Read more about UI testing.