tests: use bats for integration tests
Converted the CLI tests to using bats to get started Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
This commit is contained in:
11
Makefile
11
Makefile
@@ -27,8 +27,12 @@ cuefmt:
|
||||
cuelint: cuefmt
|
||||
@test -z "$$(git status -s . | grep -e "^ M" | grep .cue | cut -d ' ' -f3 | tee /dev/stderr)"
|
||||
|
||||
.PHONY: shellcheck
|
||||
shellcheck:
|
||||
shellcheck ./tests/*.bats ./tests/*.bash
|
||||
|
||||
.PHONY: lint
|
||||
lint: cuelint golint check-buildkit-version
|
||||
lint: shellcheck cuelint golint check-buildkit-version
|
||||
|
||||
.PHONY: check-buildkit-version
|
||||
check-buildkit-version:
|
||||
@@ -41,7 +45,10 @@ check-buildkit-version:
|
||||
integration: dagger-debug
|
||||
# Self-diagnostics
|
||||
./tests/test-test.sh 2>/dev/null
|
||||
# Actual integration tests
|
||||
# Bats based integration tests
|
||||
yarn --cwd "./tests" install
|
||||
DAGGER_BINARY="../cmd/dagger/dagger-debug" yarn --cwd "./tests" test
|
||||
# Old style integration tests tests
|
||||
DAGGER_BINARY="./cmd/dagger/dagger-debug" time ./tests/test.sh all
|
||||
|
||||
.PHONY: install
|
||||
|
Reference in New Issue
Block a user