Skip to content

Commit e8f074d

Browse files
fix(ci): Create required test databases in CouchDB setup
- Add creation of sw360_test_db, sw360changelogs, sw360spdx, sw360_test_attachments - Fixes CouchDB 'no such file or directory' error during tests
1 parent 78902a7 commit e8f074d

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

.github/workflows/build_and_test.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,12 @@ jobs:
100100
curl -s -u ${{ env.COUCHDB_USER }}:${{ env.COUCHDB_PASSWORD }} -X PUT http://localhost:5984/_node/_local/_config/cluster/r -d '"1"' || true
101101
curl -s -u ${{ env.COUCHDB_USER }}:${{ env.COUCHDB_PASSWORD }} -X PUT http://localhost:5984/_node/_local/_config/cluster/w -d '"1"' || true
102102
103+
# Create required test databases
104+
curl -s -u ${{ env.COUCHDB_USER }}:${{ env.COUCHDB_PASSWORD }} -X PUT http://localhost:5984/sw360_test_db || true
105+
curl -s -u ${{ env.COUCHDB_USER }}:${{ env.COUCHDB_PASSWORD }} -X PUT http://localhost:5984/sw360changelogs || true
106+
curl -s -u ${{ env.COUCHDB_USER }}:${{ env.COUCHDB_PASSWORD }} -X PUT http://localhost:5984/sw360spdx || true
107+
curl -s -u ${{ env.COUCHDB_USER }}:${{ env.COUCHDB_PASSWORD }} -X PUT http://localhost:5984/sw360_test_attachments || true
108+
103109
echo "CouchDB configured for single-node operation"
104110
105111
- name: Set up JDK 21

0 commit comments

Comments
 (0)