Test job env-var setting feature

This commit is contained in:
Elijah 2024-01-14 17:33:35 +01:00
parent 300474f584
commit fde3a55586
1 changed files with 4 additions and 7 deletions

View File

@ -8,10 +8,13 @@ on:
- testing-pipeline - testing-pipeline
jobs: jobs:
build: test:
runs-on: ubuntu-22.04 runs-on: ubuntu-22.04
env:
SECRET_KEY: "t3st_dummy_s3cr3t_k3y"
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
@ -39,12 +42,6 @@ jobs:
pip install --upgrade pip pip install --upgrade pip
pip install -r requirements.txt pip install -r requirements.txt
- name: Set random secret key
run: |
source venv/bin/activate
SECRET_KEY=$(python3 -c 'from django.core.management.utils import get_random_secret_key; print(get_random_secret_key())')
echo "${SECRET_KEY}"
- name: Run tests - name: Run tests
run: | run: |
source venv/bin/activate source venv/bin/activate