Skip to content

Commit

Permalink
add test status
Browse files Browse the repository at this point in the history
  • Loading branch information
enya-yx authored and enya-yx committed Feb 14, 2023
1 parent 8f71024 commit b4f280f
Showing 1 changed file with 11 additions and 13 deletions.
24 changes: 11 additions & 13 deletions .github/workflows/pull_request_push_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,6 @@ jobs:
distribution: "temurin"
- name: Run tests
run: ./gradlew clean && ./gradlew test
- name: Block PR merge on test failure
if: failure()
run: exit 1

python_lint:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -138,9 +135,7 @@ jobs:
run: |
# run only test with databricks. run in 6 parallel jobs
pytest -n 6 --cov-report term-missing --cov=feathr_project/feathr feathr_project/test --cov-config=.github/workflows/.coveragerc_db
- name: Block PR merge on test failure
if: failure()
run: exit 1
azure_synapse_test:
# might be a bit duplication to setup both the azure_synapse test and databricks test, but for now we will keep those to accelerate the test speed
runs-on: ubuntu-latest
Expand Down Expand Up @@ -210,9 +205,7 @@ jobs:
# skip databricks related test as we just ran the test; also seperate databricks and synapse test to make sure there's no write conflict
# run in 6 parallel jobs to make the time shorter
pytest -n 6 -m "not databricks" --cov-report term-missing --cov=feathr_project/feathr feathr_project/test --cov-config=.github/workflows/.coveragerc_sy
- name: Block PR merge on test failure
if: failure()
run: exit 1
local_spark_test:
runs-on: ubuntu-latest
if: github.event_name == 'schedule' || github.event_name == 'push' || github.event_name == 'pull_request' || (github.event_name == 'pull_request_target' && contains(github.event.pull_request.labels.*.name, 'safe to test'))
Expand Down Expand Up @@ -271,9 +264,7 @@ jobs:
run: |
# skip cloud related tests
pytest --cov-report term-missing --cov=feathr_project/feathr/spark_provider feathr_project/test/test_local_spark_e2e.py --cov-config=.github/workflows/.coveragerc_local
- name: Block PR merge on test failure
if: failure()
run: exit 1
registry_test:
runs-on: ubuntu-latest
if: github.event_name == 'schedule' || github.event_name == 'push' || github.event_name == 'pull_request' || (github.event_name == 'pull_request_target' && contains(github.event.pull_request.labels.*.name, 'registry test'))
Expand Down Expand Up @@ -306,9 +297,16 @@ jobs:
run: |
pytest --cov-report term-missing --cov=registry/sql-registry/registry --cov-config=registry/test/.coveragerc registry/test/test_sql_registry.py
pytest --cov-report term-missing --cov=registry/purview-registry/registry --cov-config=registry/test/.coveragerc registry/test/test_purview_registry.py
- name: Block PR merge on test failure
test_status:
runs-on: ubuntu-latest
needs: [gradle_test, databricks_test, azure_synapse_test, local_spark_test, registry_test]
if: github.event_name == 'pull_request_target'
steps:
- name: Check gradle test status
if: failure()
run: exit 1

failure_notification:
# If any failure, warning message will be sent
needs: [gradle_test, python_lint, databricks_test, azure_synapse_test, local_spark_test]
Expand Down

0 comments on commit b4f280f

Please sign in to comment.