Skip to content

Commit b1b4daf

Browse files
fix: debug CI errors
1 parent 3170861 commit b1b4daf

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626

2727
strategy:
2828
matrix:
29-
node-version: [20.x, 22.x]
29+
node-version: [22.x]
3030

3131
steps:
3232
- uses: actions/checkout@v4
@@ -76,6 +76,11 @@ jobs:
7676
# Wait for server to be ready (using wait-on http)
7777
npx wait-on http://127.0.0.1:3000/openAPI-spec.json --timeout 60000
7878
79+
# Debug connectivity
80+
echo "Testing connectivity with curl..."
81+
curl -v http://127.0.0.1:3000/openAPI-spec.json
82+
curl -v http://127.0.0.1:3000/api/v2/info || echo "API Info failed"
83+
7984
# Run tests (allow failure so we can print logs)
8085
set +e
8186
npm run test:vulnerabilities

test/vulnerabilities.test.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
require('dotenv').config();
2-
const request = require("supertest")("http://127.0.0.1/api/v2");
3-
const requestV1 = require("supertest")("http://127.0.0.1/api/v1");
2+
const port = process.env.EXPRESS_JS_PORT || 3000;
3+
console.log(`Testing against http://localhost:${port}`);
4+
const request = require("supertest")(`http://localhost:${port}/api/v2`);
5+
const requestV1 = require("supertest")(`http://localhost:${port}/api/v1`);
46
const expect = require("chai").expect;
57

68
describe("DVWS-Node Vulnerability Tests", function () {

0 commit comments

Comments
 (0)