test(spec): Control Server API secured via cross-pinning mTLS

. We are now leveraging nix for portable dependency handling.
. There are now three types of tests: client, server and end-to-end.
. server tests exercise the actual kapow server being tested, while the
requests are performed using the test steps.
. client tests exercise the actual kapow client being tested, while the
requests are served using the test steps.
. e2e test exercise the actual kapow program in its dual role of client
and server (¡como tiene que ser!).

Co-authored-by: Roberto Abdelkader Martínez Pérez <robertomartinezp@gmail.com>
This commit is contained in:
pancho horrillo
2021-03-12 17:02:42 +01:00
parent b7b55d2f3b
commit ab50721f69
17 changed files with 1587 additions and 92 deletions
+10 -13
View File
@@ -1,23 +1,20 @@
.PHONY: lint wip test fix catalog sync
.PHONY: all lint wip test fix catalog
all: checkbin sync test
all: checkbin test
sync:
pipenv sync
lint:
gherkin-lint
wip:
KAPOW_DEBUG_TESTS=1 pipenv run behave --stop --wip
KAPOW_DEBUG_TESTS=1 behave --stop --wip -k
test: lint
pipenv run behave --no-capture --tags=~@skip
behave --no-capture --tags=~@skip
fix: lint
KAPOW_DEBUG_TESTS=1 pipenv run behave --stop --no-capture --tags=~@skip
KAPOW_DEBUG_TESTS=1 behave --stop --no-capture --tags=~@skip
catalog:
pipenv run behave --format steps.usage --dry-run --no-summary -q
clean:
pipenv --rm
behave --format steps.usage --dry-run --no-summary -q
checkbin:
@which kapow >/dev/null || (echo "ERROR: Your kapow binary is not present in PATH" && exit 1)
testpoc: sync
pipenv run pip install -r ../../testutils/poc/requirements.txt
PATH=../../testutils/poc:$$PATH KAPOW_CONTROL_URL=http://localhost:8081 KAPOW_DATA_URL=http://localhost:8081 pipenv run behave --no-capture --tags=~@skip
testpoc:
PATH=../../testutils/poc:$$PATH behave --no-capture --tags=~@skip
wippoc:
PATH=../../testutils/poc:$$PATH behave --no-capture --tags=@wip -k