@arelstone/detox-helpers

1.0.2 • Public • Published

detox-helpers

This package is a set of test helpers for Detox.

Prerequisites

Installation

// with NPM
$ npm install -D @arelstone/detox-helpers

// with NPM
$ yarn install --dev @arelstone/detox-helpers

Simple Example

import {expect, action} from '@arelstone/detox-helpers'

describe('My first tets', ()=>{
    it('should see Hello World', async () => {
        await expect.toExist('UniqueId205');
        await expect.toHaveText('UniqueId205', 'Hello world')
    });

    it('should type in InputField', () => {
        await expect.toExist('UniqueId210');
        await action.typeText('UniqueId210', 'Some text that is typed into the input field')
    });

    it('should replace the text in the InputField', () => {
        await action.typeText('UniqueId210', 'Some new value')
    });
});

Contributing

Pull requests is VERY welcome. Just make fork, do your changes and make a pull request.

Roadmap

  • [x] Add test utilities
  • [ ] Write documentation
  • [ ] Testing

Package Sidebar

Install

npm i @arelstone/detox-helpers

Weekly Downloads

1

Version

1.0.2

License

MIT

Unpacked Size

15.3 kB

Total Files

10

Last publish

Collaborators

  • arelstone