mirror of https://github.com/statping/statping
test fix for postman sqlite, postgres, and sqlite.
parent
bcd38ec668
commit
86204d27bd
|
@ -10,7 +10,7 @@ services:
|
||||||
POSTGRES_DB: statping
|
POSTGRES_DB: statping
|
||||||
POSTGRES_USER: root
|
POSTGRES_USER: root
|
||||||
ports:
|
ports:
|
||||||
- "127.0.0.1:5432:5432"
|
- 5432:5432
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD-SHELL", "pg_isready -U root"]
|
test: ["CMD-SHELL", "pg_isready -U root"]
|
||||||
interval: 15s
|
interval: 15s
|
||||||
|
@ -27,7 +27,7 @@ services:
|
||||||
MYSQL_USER: root
|
MYSQL_USER: root
|
||||||
MYSQL_PASSWORD: password123
|
MYSQL_PASSWORD: password123
|
||||||
ports:
|
ports:
|
||||||
- "127.0.0.1:3306:3306"
|
- 3306:3306
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: [ "CMD", "mysqladmin" ,"ping", "-h", "localhost" ]
|
test: [ "CMD", "mysqladmin" ,"ping", "-h", "localhost" ]
|
||||||
timeout: 20s
|
timeout: 20s
|
||||||
|
|
|
@ -17,17 +17,17 @@
|
||||||
"script": {
|
"script": {
|
||||||
"id": "29b5dc8d-60c1-4f70-853d-49114af6b254",
|
"id": "29b5dc8d-60c1-4f70-853d-49114af6b254",
|
||||||
"exec": [
|
"exec": [
|
||||||
"var tm = Math.round(new Date().getTime()/1000);",
|
"var tm = Math.round(new Date().getTime() / 1000);",
|
||||||
"pm.globals.set(\"start_time\", tm-259200);",
|
"pm.globals.set(\"start_time\", tm - 259200);",
|
||||||
"pm.globals.set(\"end_time\", tm);",
|
"pm.globals.set(\"end_time\", tm);",
|
||||||
"",
|
"",
|
||||||
"pm.test(\"Response is ok\", function () {",
|
"pm.test(\"Response is ok\", function () {",
|
||||||
" pm.response.to.have.status(200);",
|
" pm.response.to.have.status(200);",
|
||||||
"});",
|
"});",
|
||||||
"",
|
"",
|
||||||
"pm.test(\"Check Core API Route\", function () {",
|
"pm.test(\"Check Setup\", function () {",
|
||||||
" var jsonData = pm.response.json();",
|
" var jsonData = pm.response.json();",
|
||||||
" pm.expect(jsonData.config.connection).to.eql(\"sqlite3\");",
|
" pm.expect(jsonData.message).to.eql(\"success\");",
|
||||||
"});"
|
"});"
|
||||||
],
|
],
|
||||||
"type": "text/javascript"
|
"type": "text/javascript"
|
||||||
|
@ -46,14 +46,7 @@
|
||||||
],
|
],
|
||||||
"request": {
|
"request": {
|
||||||
"auth": {
|
"auth": {
|
||||||
"type": "bearer",
|
"type": "noauth"
|
||||||
"bearer": [
|
|
||||||
{
|
|
||||||
"key": "token",
|
|
||||||
"value": "{{api_key}}",
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"method": "POST",
|
"method": "POST",
|
||||||
"header": [
|
"header": [
|
||||||
|
@ -69,7 +62,7 @@
|
||||||
"urlencoded": [
|
"urlencoded": [
|
||||||
{
|
{
|
||||||
"key": "db_host",
|
"key": "db_host",
|
||||||
"value": "localhost",
|
"value": "{{db_host}}",
|
||||||
"type": "text"
|
"type": "text"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue