File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4545 cp .env.example .env
4646 make test-unit
4747 - name : " Save the result of fast test suite"
48- run : |
49- docker cp lung_cancer_screening-web:/tmp/coverage.xml ./coverage.xml
50-
48+ uses : actions/upload-artifact@v2
49+ with :
50+ name : coverage.xml
51+ path : coverage.xml
5152
5253 test-lint :
5354 name : " Linting"
9091 uses : actions/checkout@v6
9192 with :
9293 fetch-depth : 0 # Full history is needed to improving relevancy of reporting
94+ - name : Download coverage report
95+ uses : actions/download-artifact@v2
96+ with :
97+ name : coverage.xml
9398 - name : " Perform static analysis"
9499 uses : ./.github/actions/perform-static-analysis
95100 with :
Original file line number Diff line number Diff line change @@ -22,3 +22,4 @@ lung_cancer_screening/assets/compiled/*
2222tests /TEST- * .xml
2323node_modules
2424.coverage
25+ coverage.xml
Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ services:
77 dockerfile : Dockerfile
88 target : development
99 command : python manage.py runserver 0.0.0.0:8000
10+ user : " ${UID}:${GID}"
1011 ports :
1112 - " 8000:8000"
1213 env_file :
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ omit = [
4343 " */tests/*" ,
4444 " manage.py"
4545]
46- data_file = " /tmp/ .coverage"
46+ data_file = " .coverage"
4747
4848[tool .coverage .xml ]
49- output = " /tmp/ coverage.xml"
49+ output = " coverage.xml"
Original file line number Diff line number Diff line change @@ -5,5 +5,5 @@ sonar.qualitygate.wait=true
55sonar.sourceEncoding =UTF-8
66sonar.sources =.
77
8- # sonar.python.coverage.reportPaths=.coverage/ coverage.xml
8+ sonar.python.coverage.reportPaths =coverage.xml
99# sonar.[javascript|typescript].lcov.reportPaths=.coverage/lcov.info
Original file line number Diff line number Diff line change 3333 TEST_MODULE=" "
3434fi
3535
36- docker compose run --rm --remove-orphans web sh -c \
36+ echo " Running as app user: $( id -u) :$( id -g) "
37+ UID=$( id -u) GID=$( id -u) docker compose run --rm --remove-orphans web sh -c \
3738 " echo 'Running unit tests...' && \
3839 poetry run coverage run manage.py test $TEST_MODULE $TAG \
3940 --settings=lung_cancer_screening.settings_test \
You can’t perform that action at this time.
0 commit comments