Real-Test
Package that provides real e2e tests.
Installation
$ sudo apt-get install xvfb # just to run hidden tests $ npm install -g nightwatch$ npm install -g real-test
Quick Start
$ real-test -c /home/user/documents/configs/example.json
to see more options:
$ real-test -h
Advantages
- Real test E2E
- Easy to write tests
- Componentized
Configuration
- If action url does not have a value attribute, the app will use url attribute in json
- You can set global variables, these variables will change in tests files (example: {"action": "pause", "value": "!!timeout"})
Actions
- Header: some information to test(needs be the first action)
- IMPORTANT: you can't write action header with 'only' and 'notOnly' at same time
- Import: import json inside test
- IMPORTANT: You need set header type helper to import a file
- Assert: compare something
- Cookie: write or assert
- Click: click on selector
- Desktop: change to view desktop
- Phone: change to view phone
- Tablet: change to view tablet
- Log: log into console
- Pause: Pause the test for X milliseconds
- Write: Write text
- Url: Access url
All actions are in actions folder