mirror of
https://github.com/kreuzwerker/terraform-provider-docker.git
synced 2025-12-20 22:59:42 -05:00
* chore: runs v2 upgrade cmd * chore: moves all files into the internal provider dir * feat: migrates main and provider * fix: migrates tests to provider factories * fix: replace import state passthrough ctx func * chore: bump tf-sdk to v2.4.4 * fix: acc test by adding stop grace period * fix: move to validate diag functions * test: switch from ctx TODO to Background * feat: add state upgrade for restart_policy and auth Co-authored-by: Shunsuke Suzuki <suzuki-shunsuke@users.noreply.github.com>
29 lines
508 B
Bash
Executable file
29 lines
508 B
Bash
Executable file
#!/bin/bash
|
|
set -e
|
|
|
|
log() {
|
|
echo "####################"
|
|
echo "## -> $1 "
|
|
echo "####################"
|
|
}
|
|
|
|
setup() {
|
|
sh "$(pwd)"/scripts/testacc_setup.sh
|
|
}
|
|
|
|
run() {
|
|
go clean -testcache
|
|
TF_ACC=1 go test ./internal/provider -v -timeout 120m
|
|
|
|
# keep the return value for the scripts to fail and clean properly
|
|
return $?
|
|
}
|
|
|
|
cleanup() {
|
|
sh "$(pwd)"/scripts/testacc_cleanup.sh
|
|
}
|
|
|
|
## main
|
|
log "setup" && setup
|
|
log "run" && run || (log "cleanup" && cleanup && exit 1)
|
|
log "cleanup" && cleanup
|