Skip to content

Commit

Permalink
Merge pull request #51 from openimis/feature/ci-all-modules
Browse files Browse the repository at this point in the history
test fetching all module for test
delcroip authored Nov 5, 2021
2 parents 28d828b + 5cf061a commit 6a3bd3b
Showing 2 changed files with 7 additions and 8 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -45,12 +45,15 @@ jobs:
- name: Initialize DB
run: |
wget https://raw.githubusercontent.com/openimis/database_ms_sqlserver/develop/Empty%20databases/openIMIS_ONLINE.sql -O openIMIS_ONLINE.sql
wget https://raw.githubusercontent.com/openimis/database_ms_sqlserver/develop/Demo%20database/openIMIS_demo_ONLINE.sql -O openIMIS_demo_ONLINE.sql
export DBBRANCH="$([ $GITHUB_REF == 'develop' ] && echo "main" || echo "develop")"
wget https://raw.githubusercontent.com/openimis/database_ms_sqlserver/$DBBRANCH/Empty%20databases/openIMIS_ONLINE.sql -O openIMIS_ONLINE.sql
wget https://raw.githubusercontent.com/openimis/database_ms_sqlserver/$DBBRANCH/Demo%20database/openIMIS_demo_ONLINE.sql -O openIMIS_demo_ONLINE.sql
curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
curl https://packages.microsoft.com/config/ubuntu/20.04/prod.list | sudo tee /etc/apt/sources.list.d/msprod.list
sudo apt-get update
sudo apt-get install mssql-tools unixodbc-dev
sudo apt-get install mssql-tools unixodbc-dev jq
/opt/mssql-tools/bin/sqlcmd -S localhost -U SA -P $SA_PASSWORD -Q 'DROP DATABASE IF EXISTS imis'
/opt/mssql-tools/bin/sqlcmd -S localhost -U SA -P $SA_PASSWORD -Q 'CREATE DATABASE imis'
/opt/mssql-tools/bin/sqlcmd -S localhost -U SA -P $SA_PASSWORD -d imis -i openIMIS_ONLINE.sql | grep . | uniq -c
@@ -70,7 +73,7 @@ jobs:
ls -l
python manage.py migrate
python init_test_db.py | grep . | uniq -c
python manage.py test --keepdb
python manage.py test --keepdb $(jq -r '(.modules[]|.name)' ../openimis.json)
env:
SECRET_KEY: secret
DEBUG: true
4 changes: 0 additions & 4 deletions openimis.json
Original file line number Diff line number Diff line change
@@ -52,10 +52,6 @@
"name": "claim_batch",
"pip": "git+https://github.com/openimis/openimis-be-claim_batch_py.git@develop#egg=openimis-be-claim_batch"
},
{
"name": "api_fhir",
"pip": "git+https://github.com/openimis/openimis-be-api_fhir_py.git@develop#egg=openimis-be-api_fhir"
},
{
"name": "dhis2_etl",
"pip": "git+https://github.com/openimis/openimis-be-dhis2_etl_py.git@develop#egg=openimis-be-dhis2_etl"

0 comments on commit 6a3bd3b

Please sign in to comment.