Skip to content

Commit

Permalink
feat(devinfra): Add test coverage to CI to measure the covering code …
Browse files Browse the repository at this point in the history
…of unitest (PySpark) (#601)
  • Loading branch information
Elssky authored Aug 21, 2024
1 parent b5ebedb commit 359b829
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/pyspark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,12 @@ jobs:
working-directory: pyspark
run: make install_test

- name: Run PyTest
- name: Run PyTest and Generate Coverage Report
working-directory: pyspark
run: make test
run: make coverage_report

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
files: ./coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}
2 changes: 1 addition & 1 deletion pyspark/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ test:
coverage_report:
export JAVA_HOME=${JAVA_HOME_11_X64}
export SPARK_TESTING=1
poetry run pytest --cov --cov-report=html:coverage_html graphar_pyspark tests/
poetry run pytest --cov --cov-report=html:coverage_html --cov-report=xml graphar_pyspark tests/

.PHONY: install_lint
install_lint:
Expand Down

0 comments on commit 359b829

Please sign in to comment.