add e2e testing documentation to README.md

This commit is contained in:
MarconLP 2023-05-05 01:28:32 +02:00
parent d02c005939
commit 861cf52cde
No known key found for this signature in database
GPG key ID: A08A9C8B623F5EA5

View file

@ -37,19 +37,19 @@
git clone https://github.com/MarconLP/snapify.git git clone https://github.com/MarconLP/snapify.git
``` ```
1. Go to the project folder 2. Go to the project folder
```sh ```sh
cd snapify cd snapify
``` ```
1. Install packages with yarn 3. Install packages with yarn
```sh ```sh
npm i npm i
``` ```
1. Set up your .env file 4. Set up your .env file
- Duplicate `.env.example` to `.env` - Duplicate `.env.example` to `.env`
- Use `openssl rand -base64 32` to generate a key and add it under `NEXTAUTH_SECRET` in the .env file. - Use `openssl rand -base64 32` to generate a key and add it under `NEXTAUTH_SECRET` in the .env file.
- Fill in the other variables - Fill in the other variables
@ -61,6 +61,15 @@
npm run dev npm run dev
``` ```
### E2E-Testing
Be sure to set the environment variable `NEXTAUTH_URL` to the correct value. If you are running locally, as the documentation within `.env.example` mentions, the value should be `http://localhost:3000`.
```sh
# In a terminal just run:
npm run test:e2e
```
## Deployment ## Deployment
### Vercel ### Vercel