generated from hackforla/.github-hackforla-base-repo-template
-
-
Notifications
You must be signed in to change notification settings - Fork 33
52 lines (46 loc) · 1.84 KB
/
tdm-server-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: tdm-server-test
run-name: ${{ github.actor }} is running tests for the server
on:
pull_request:
branches:
- develop
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '14'
- name: Change directory
run: cd server
- name: Install dependencies
run: npm install
working-directory: server
- name: Set up environment variables
run: |
echo "TEST_ENV=true" >> .env
echo "PORT=5002" >> .env
echo "NODE_OPTIONS=--trace-deprecation" >> .env
echo "JWT_SECRET_KEY=testingSecretKey" >> .env
echo "CLIENT_URL=http://localhost:3001" >> .env
echo "SERVER_URL=http://localhost:5002" >> .env
echo "SENDGRID_API_KEY=SG.testAPIkey" >> .env
echo "[email protected]" >> .env
echo "EMAIL_PUBLIC_COMMENT_LA_CITY=tdm+devpubliccommentplanning@test.org" >> .env
echo "[email protected]" >> .env
echo "APPLICATIONINSIGHTS_CONNECTION_STRING=InstrumentationKey=00000000-0000-0000-0000-000000000000;IngestionEndpoint=https://westus-0.in.applicationinsights.azure.com/;LiveEndpoint=https://westus.livediagnostics.monitor.azure.com/" >> .env
echo "[email protected]" >> .env
echo "SECURITY_ADMIN_PASSWORD=Dogfood1!" >> .env
echo "SQL_SERVER_NAME=localhost" >> .env
echo "SQL_SERVER_PORT=1434" >> .env
echo "SQL_DATABASE_NAME=tdmtestdb" >> .env
echo "SQL_USER_NAME=sa" >> .env
echo "SQL_PASSWORD=TestPassw0rd" >> .env
echo "SQL_ENCRYPT=false" >> .env
working-directory: server
- name: Run tests
run: npm test
working-directory: server