File tree Expand file tree Collapse file tree 1 file changed +16
-4
lines changed Expand file tree Collapse file tree 1 file changed +16
-4
lines changed Original file line number Diff line number Diff line change @@ -87,18 +87,30 @@ jobs:
87
87
uses : taiki-e/install-action@cargo-llvm-cov
88
88
89
89
- name : Set up BigQuery environment variables and credentials
90
+ if : ${{ secrets.TESTS_BIGQUERY_SA_KEY_JSON != '' && secrets.TESTS_BIGQUERY_PROJECT_ID != '' }}
90
91
run : |
91
92
printf '%s' '${{ secrets.TESTS_BIGQUERY_SA_KEY_JSON }}' > /tmp/bigquery-sa-key.json
92
93
echo "TESTS_BIGQUERY_PROJECT_ID=${{ secrets.TESTS_BIGQUERY_PROJECT_ID }}" >> $GITHUB_ENV
93
94
echo "TESTS_BIGQUERY_SA_KEY_PATH=/tmp/bigquery-sa-key.json" >> $GITHUB_ENV
95
+ echo "BIGQUERY_TESTS_ENABLED=true" >> $GITHUB_ENV
94
96
95
97
- name : Generate code coverage
96
98
id : coverage
97
99
run : |
98
- cargo llvm-cov test \
99
- --workspace --no-fail-fast \
100
- --all-features \
101
- --lcov --output-path lcov.info
100
+ if [ "$BIGQUERY_TESTS_ENABLED" = "true" ]; then
101
+ echo "Running all tests including BigQuery integration tests"
102
+ cargo llvm-cov test \
103
+ --workspace --no-fail-fast \
104
+ --all-features \
105
+ --lcov --output-path lcov.info
106
+ else
107
+ echo "Running tests excluding BigQuery integration tests (credentials not available)"
108
+ cargo llvm-cov test \
109
+ --workspace --no-fail-fast \
110
+ --all-features \
111
+ --lcov --output-path lcov.info \
112
+ -- --skip bigquery
113
+ fi
102
114
103
115
- name : Upload coverage to Coveralls
104
116
uses : coverallsapp/github-action@v2
You can’t perform that action at this time.
0 commit comments