Skip to content

Commit b7008e2

Browse files
committed
fix: use CI-standard Newman variable names (base_url, admin_user, admin_password)
CI workflow passes base_url/admin_user/admin_password but the collection used baseUrl/username/password. Mismatched names caused Newman to silently fall back to the collection default of http://localhost (port 80), which nothing answers in CI — resulting in ECONNREFUSED. Also updates default base_url to http://localhost:8080 to match the PHP built-in server CI starts for Newman tests.
1 parent be02e73 commit b7008e2

2 files changed

Lines changed: 13 additions & 10 deletions

File tree

tests/integration/README.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,14 @@ enable-newman: true
1515
```bash
1616
npm install -g newman
1717
newman run tests/integration/app-template.postman_collection.json \
18-
--env-var baseUrl=http://localhost \
19-
--env-var username=admin \
20-
--env-var password=admin
18+
--env-var base_url=http://nextcloud.local \
19+
--env-var admin_user=admin \
20+
--env-var admin_password=admin
2121
```
2222

23+
The variable names (`base_url`, `admin_user`, `admin_password`) match what the CI workflow passes.
24+
In CI the server runs on `http://localhost:8080` (PHP built-in server); locally use `http://nextcloud.local`.
25+
2326
## Structure
2427

2528
Add your Postman collection JSON files to this directory. The CI runner picks up

tests/integration/app-template.postman_collection.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,29 +10,29 @@
1010
"basic": [
1111
{
1212
"key": "username",
13-
"value": "{{username}}",
13+
"value": "{{admin_user}}",
1414
"type": "string"
1515
},
1616
{
1717
"key": "password",
18-
"value": "{{password}}",
18+
"value": "{{admin_password}}",
1919
"type": "string"
2020
}
2121
]
2222
},
2323
"variable": [
2424
{
25-
"key": "baseUrl",
26-
"value": "http://localhost",
25+
"key": "base_url",
26+
"value": "http://localhost:8080",
2727
"type": "string"
2828
},
2929
{
30-
"key": "username",
30+
"key": "admin_user",
3131
"value": "admin",
3232
"type": "string"
3333
},
3434
{
35-
"key": "password",
35+
"key": "admin_password",
3636
"value": "admin",
3737
"type": "string"
3838
}
@@ -45,7 +45,7 @@
4545
"name": "Nextcloud status",
4646
"request": {
4747
"method": "GET",
48-
"url": "{{baseUrl}}/status.php",
48+
"url": "{{base_url}}/status.php",
4949
"description": "Verify Nextcloud is running."
5050
},
5151
"event": [

0 commit comments

Comments
 (0)