Skip to content

Commit 7f7132e

Browse files
authored
Improve CI: save a test result in case of test failure. (#99)
1 parent 1953298 commit 7f7132e

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

.github/workflows/CI.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,4 +57,16 @@ jobs:
5757
run: bash GitHubActions/build_sqlite_fdw.sh ${{ matrix.pg }}
5858

5959
- name: execute sqlite_fdw test
60-
run: bash GitHubActions/execute_test.sh ${{ matrix.pg }}
60+
run: bash GitHubActions/execute_test.sh ${{ matrix.pg }}
61+
62+
- name: download output files (regression.diffs)
63+
if: failure()
64+
uses: actions/upload-artifact@v4
65+
with:
66+
name: ${{ matrix.pg }}-test-results
67+
path: |
68+
workdir/postgresql-${{ matrix.pg }}/contrib/sqlite_fdw/regression.diffs
69+
workdir/postgresql-${{ matrix.pg }}/contrib/sqlite_fdw/regression.out
70+
workdir/postgresql-${{ matrix.pg }}/contrib/sqlite_fdw/results
71+
retention-days: 7
72+

GitHubActions/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,6 @@ Scripts in this directory (GitHubActions/*.sh) are referred by CI.yml.
88

99
The regression test will be executed for multi-versions of PostgreSQL.
1010
Target versions are determined automatically based on directory names in "sql" directory.
11+
12+
If the regression test failed, test result files (result directory, regression.diff amd regression.out) are uploaded as artifacts.
13+
7 days later, artifact files will be deleted.

0 commit comments

Comments
 (0)