refactor: ensure in-memory database consistency

test: update authifier to allow for in-memory tests
ci: explicitly run in-memory and mongo tests
This commit is contained in:
Paul Makles
2023-09-10 14:49:27 +01:00
parent 055deab105
commit 6838b0b1f0
12 changed files with 92 additions and 58 deletions

View File

@@ -30,23 +30,26 @@ jobs:
run: |
docker-compose -f docker-compose.db.yml up -d
- name: Copy .env.example
if: github.event_name != 'pull_request' && github.ref_name == 'master'
run: |
cp .env.example .env
- name: Run cargo test
uses: actions-rs/cargo@v1
env:
TEST_DB: REFERENCE
with:
command: test
- name: Run cargo test (with MongoDB)
uses: actions-rs/cargo@v1
env:
TEST_DB: MONGODB
MONGODB: mongodb://localhost
with:
command: test
- name: Copy .env.example
if: github.event_name != 'pull_request' && github.ref_name == 'master'
run: |
cp .env.example .env
- name: Start API in background
if: github.event_name != 'pull_request' && github.ref_name == 'master'
run: |