photo

Azgaar

Created: Sun Nov 22 2020Updated: Thu Jan 21 2021

CypressTest

CypressTest is a test package created to playtest cypress.io and perform a simple test task: send email via gmail api to instant mailbox and run cypress test to log email body to console

Installation

CypressTest requires Node.js v10.15+ to run.

Clone repository and install dependencies (cypress and googleapis).

$ git clone https://github.com/Azgaar/cypresstest.git
$ cd cypresstest
$ npm install

Usage

Run index.js to generate test email and send it via gmail api. Then run cypress test in background mode. You will need access token to use gmail api. I can send it separately or a new one can be generated (it will require manual step from my side):

$ npm test

Send a test email via gmail api:

$ node sender.js

Open Cypress UI and run test manually:

$ npm cy:open

Amend cypress/fixtures/mailinator.json to set up test data if required.

License

MIT