test: env version tests

See coop-cloud/organising#541
This commit is contained in:
2024-07-17 10:06:46 +02:00
parent d22e2c38ce
commit 8084bff104
9 changed files with 201 additions and 9 deletions

View File

@ -187,6 +187,24 @@ test_cmd_export"
assert_output --partial 'baz'
}
# bats test_tags=slow
@test "respects env version" {
tagHash=$(_get_tag_hash "0.1.0+1.20.0")
run $ABRA app deploy "$TEST_APP_DOMAIN" "0.1.0+1.20.0" --no-input
assert_success
run grep -q "TYPE=$TEST_RECIPE:0.1.0+1.20.0" \
"$ABRA_DIR/servers/$TEST_SERVER/$TEST_APP_DOMAIN.env"
assert_success
run $ABRA app cmd "$TEST_APP_DOMAIN" app test_cmd
assert_success
assert_output --partial 'baz'
assert_equal $(_get_current_hash) "$tagHash"
}
# bats test_tags=slow
@test "error if missing service" {
_deploy_app