Greenstand / Greenstand/treetracker-admin-api
First Cypress integration test: user login.
- Dominant language
- TypeScript
- Stars
- 32
- Forks
- 85
- PR merge metrics
- No merged PRs in 30d
Description
Currently, in admin panel, we have installed Cypress and have some experimental tests under client/cypress/integration, now we need to put them together to work correctly, requirements:
* A new command under server folder
```
cd server
npm run start:integration
```
to run a special server for the integration tests only. The major difference from the normal server is that it would seed data for test automatically.
* Seed basic data into the DB
Currently, just need minimal data for user login. Like: a user record in 'amdin_user', and some necessary data like: admin roles. With these data, we can emulate user login in the first integration test.
* Cypress test: login
Build a test to login using the data seeded in DB by the step above. (We already have some basic setting for Cypress and example tests under client/cypress/integration folder)
So in this way, we can run the login test and all the data is self-sufficient, we just need a connection to connect to the database.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.