fixed test, and added more failure modes

Signed-off-by: Richard Jones <richard@dagger.io>
This commit is contained in:
Richard Jones
2021-12-14 14:29:20 -07:00
parent e65b3cfa4a
commit c422512155
7 changed files with 167 additions and 28 deletions

View File

@@ -4,13 +4,37 @@ setup() {
common_setup
}
@test "plan: hello" {
@test "plan/hello" {
# Europa loader handles the cwd differently, therefore we need to CD into the tree at or below the parent of cue.mod
cd "$TESTDIR"
"$DAGGER" --europa up ./plan/hello-europa
}
@test "plan: unix socket" {
@test "plan/context/services invalid schema" {
cd "$TESTDIR"
"$DAGGER" --europa up ./plan/context/services/unix
run "$DAGGER" --europa up ./plan/context/services/invalid_schema.cue
assert_failure
}
@test "plan/context/services invalid value" {
cd "$TESTDIR"
run "$DAGGER" --europa up ./plan/context/services/invalid_value.cue
assert_failure
}
@test "plan/context/services incomplete unix" {
cd "$TESTDIR"
run "$DAGGER" --europa up ./plan/context/services/incomplete_unix.cue
assert_failure
}
@test "plan/context/services incomplete service" {
cd "$TESTDIR"
run "$DAGGER" --europa up ./plan/context/services/incomplete_service.cue
assert_output --partial "pipeline was partially executed because of missing inputs"
}
@test "plan/context/services unix" {
cd "$TESTDIR"
"$DAGGER" --europa up ./plan/context/services/unix.cue
}