Skip to content

Commit 6509388

Browse files
authored
Merge pull request #240 from HarperFast/integration-apitest-upd
simplify apiTests "upload logs on failure" step condition and upload available output and logs on failure
2 parents a475494 + cec6b87 commit 6509388

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

.github/workflows/integration-tests.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,10 @@ jobs:
112112
THREADS_DEBUG: false
113113
NODE_HOSTNAME: 'localhost'
114114
run: |
115-
node ./dist/bin/harper.js install
115+
mkdir -p /tmp/hdb/log
116+
node ./dist/bin/harper.js install > /tmp/hdb/log/install-stdout.log 2> /tmp/hdb/log/install-stderr.log
116117
sleep 10
117-
node ./dist/bin/harper.js start
118+
node ./dist/bin/harper.js start > /tmp/hdb/log/start-stdout.log 2> /tmp/hdb/log/start-stderr.log &
118119
sleep 10
119120
120121
- name: Run API Tests
@@ -125,12 +126,13 @@ jobs:
125126
run: npm run test:integration:api-tests
126127

127128
- name: Upload Harper logs
128-
if: steps.run-api-tests.outcome == 'failure'
129+
if: failure()
129130
uses: actions/upload-artifact@v7
130131
with:
131132
name: harper-integration-api-test-logs-node-${{ matrix.node-version }}
132-
path: /tmp/hdb/log/hdb.log
133-
retention-days: 2
133+
path: /tmp/hdb/log/
134+
retention-days: 3
135+
if-no-files-found: ignore
134136

135137
run-integration-tests:
136138
name: Integration Tests ${{matrix.shard}}/4 (Node.js v${{ matrix.node-version }})

0 commit comments

Comments
 (0)