-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (34 loc) · 1.05 KB
/
ci.yaml
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
name: ci
on:
pull_request:
branches:
- main
- dev
jobs:
build_and_test:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout branch
uses: actions/checkout@v4
with:
submodules: recursive
token: ${{ secrets.PAT_TOKEN }}
# See https://github.com/marketplace/actions/setup-micromamba
- name: Install conda env
uses: mamba-org/setup-micromamba@v1.8.1
with:
environment-file: environment.yml
environment-name: lidro # activate the environment
cache-environment: true
cache-downloads: true
generate-run-shell: true
- name: Unit test
shell: micromamba-shell {0}
run: |
cp .env_example .env
sed -i "s/DB_UNI_USER='TO_BE_DEFINED'/DB_UNI_USER=${{ secrets.DB_UNI_USER }}/g" .env
sed -i "s/DB_UNI_PASSWORD='TO_BE_DEFINED'/DB_UNI_PASSWORD=${{ secrets.DB_UNI_PASSWORD }}/g" .env
python -m pytest -s --log-cli-level DEBUG