Merge pull request 'fix: try fix test runs' (#101) from fix/sql_server_test into main
Reviewed-on: #101
This commit is contained in:
commit
fa641d29c5
3 changed files with 9 additions and 6 deletions
7
.github/actions/acc_test/action.yaml
vendored
7
.github/actions/acc_test/action.yaml
vendored
|
|
@ -245,12 +245,13 @@ runs:
|
||||||
go test -v ${testfile} -timeout=${{ inputs.test_timeout_string }} | tee -a acc_test_run.log
|
go test -v ${testfile} -timeout=${{ inputs.test_timeout_string }} | tee -a acc_test_run.log
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
if [[ $(cat acc_test_run.log | grep "FAIL") ]]; then
|
have_fail=$(cat acc_test_run.log | grep FAIL)
|
||||||
|
if [[ -n $have_fail ]]; then
|
||||||
echo "::endgroup::"
|
echo "::endgroup::"
|
||||||
echo "::group::go test result"
|
echo "::group::go test result"
|
||||||
echo "Test failed, see acc_test_run.log for details"
|
echo "Test failed, see acc_test_run.log for details"
|
||||||
res=$(cat acc_test_run.log | grep -v "=== RUN" | grep -v "\-\-\- PASS" | grep -v "=== CONT" | grep -v "=== PAUSE")
|
echo "${have_fail}"
|
||||||
echo "result=FAIL: ${res}" >> "$GITHUB_OUTPUT"
|
echo "result=<b>FAIL:</b> <br />${have_fail}" >> "$GITHUB_OUTPUT"
|
||||||
echo "::endgroup::"
|
echo "::endgroup::"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
6
.github/workflows/tf-acc-test.yaml
vendored
6
.github/workflows/tf-acc-test.yaml
vendored
|
|
@ -16,11 +16,13 @@ on:
|
||||||
type: boolean
|
type: boolean
|
||||||
default: false
|
default: false
|
||||||
required: true
|
required: true
|
||||||
|
|
||||||
test_timeout_string:
|
test_timeout_string:
|
||||||
description: "string that determines the timeout (default: 45m)"
|
description: "string that determines the timeout (default: '120m')"
|
||||||
type: string
|
type: string
|
||||||
default: '90m'
|
default: '120m'
|
||||||
required: true
|
required: true
|
||||||
|
|
||||||
test_file:
|
test_file:
|
||||||
description: "string that determines the test file to run (default all tests)"
|
description: "string that determines the test file to run (default all tests)"
|
||||||
type: choice
|
type: choice
|
||||||
|
|
|
||||||
|
|
@ -212,7 +212,7 @@ func TestAccInstance(t *testing.T) {
|
||||||
PreConfig: func() {
|
PreConfig: func() {
|
||||||
t.Logf("testing: %s - %s", t.Name(), "update storage.size and verify")
|
t.Logf("testing: %s - %s", t.Name(), "update storage.size and verify")
|
||||||
},
|
},
|
||||||
ExpectNonEmptyPlan: true,
|
ExpectNonEmptyPlan: false,
|
||||||
Config: testutils.StringFromTemplateMust(
|
Config: testutils.StringFromTemplateMust(
|
||||||
"testdata/instance_template.gompl",
|
"testdata/instance_template.gompl",
|
||||||
updSizeData,
|
updSizeData,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue