Add simple test for conf.d

This commit is contained in:
Tobias Reisinger 2020-11-19 13:37:26 +01:00
parent ce59bb364f
commit 1bbaeacc84
4 changed files with 16 additions and 2 deletions

View file

@ -0,0 +1,3 @@
[core]
not-found-content = "CONF.D WORKING"
not-found-content-type = "text/plain"

View file

@ -1,10 +1,9 @@
[core] [core]
database = "emgauwa-core.sqlite" database = "emgauwa-core.sqlite"
include = "../emgauwa-core-testing.conf.d"
content-dir = "." content-dir = "."
not-found-file = "404.html" not-found-file = "404.html"
not-found-file-mime = "text/html" not-found-file-mime = "text/html"
not-found-content = "404 - NOT FOUND"
not-found-content-type = "text/plain"
[ports] [ports]
server = 5000 server = 5000

View file

@ -0,0 +1,3 @@
[core]
not-found-content = '{"msg": "conf.d working"}'
not-found-content-type = "application/json"

View file

@ -14,3 +14,12 @@ stages:
method: GET method: GET
response: response:
status_code: 404 status_code: 404
- name: "[test_basics] verify conf.d by 404"
request:
url: "http://localhost:5000/invalid_url_for_testing_do_not_use"
method: GET
response:
status_code: 404
json:
msg: "conf.d working"