File tree Expand file tree Collapse file tree 5 files changed +12
-12
lines changed Expand file tree Collapse file tree 5 files changed +12
-12
lines changed Original file line number Diff line number Diff line change 1
1
name : build-ami
2
- on :
2
+ on :
3
3
push :
4
4
branches : [master]
5
5
paths : [environment/**]
Original file line number Diff line number Diff line change 1
1
name : Release
2
- on :
2
+ on :
3
3
release :
4
4
types : [published]
5
5
jobs :
Original file line number Diff line number Diff line change @@ -46,13 +46,13 @@ jobs:
46
46
with :
47
47
aws-region : us-west-1
48
48
role-to-assume : arn:aws:iam::342840881361:role/SandboxUser
49
- - run : go test ./task -v -timeout=30m -count=1
49
+ - run : go test ./task -v -timeout=30m -count=1 -tags=smoke
50
50
- if : always()
51
51
uses : actions/checkout@v2
52
52
with :
53
53
ref : master
54
54
- if : always()
55
- run : go test ./task -v -timeout=30m -count=1
55
+ run : go test ./task -v -timeout=30m -count=1 -tags=smoke
56
56
env :
57
57
SMOKE_TEST_SWEEP : true
58
58
test-k8s :
@@ -110,7 +110,7 @@ jobs:
110
110
-e 's/\n/%0A/g;' \
111
111
-e 's/\r/%0D/g;' \
112
112
-e 's/(.+)/::add-mask::\1\n::set-output name=kubeconfig::\1\n/g'
113
- - run : go test ./task -v -timeout=30m -count=1
113
+ - run : go test ./task -v -timeout=30m -count=1 -tags=smoke
114
114
env :
115
115
KUBECONFIG_DATA : ${{ steps.cluster.outputs.kubeconfig }}
116
116
SMOKE_TEST_ENABLE_K8S : true
Original file line number Diff line number Diff line change @@ -15,10 +15,10 @@ install:
15
15
GOBIN=${INSTALL_PATH} go install
16
16
17
17
test :
18
- go test ./... ${TESTARGS} -timeout=30s -parallel=4 -short
18
+ go test ./... ${TESTARGS} -timeout=30s -parallel=4
19
19
20
20
smoke :
21
- go test ./task -v ${TESTARGS} -timeout=30m -count=1
21
+ go test ./task -v ${TESTARGS} -timeout=30m -count=1 -tags=smoke
22
22
23
23
sweep :
24
24
SMOKE_TEST_SWEEP=true go test ./task -v ${TESTARGS} -timeout=30m -count=1
Original file line number Diff line number Diff line change
1
+ //go:build smoke
2
+
1
3
package task
2
4
3
5
import (
@@ -17,11 +19,9 @@ import (
17
19
"terraform-provider-iterative/task/common"
18
20
)
19
21
20
- func TestTask (t * testing.T ) {
21
- if testing .Short () {
22
- t .Skip ("go test -short detected, skipping smoke tests" )
23
- }
24
-
22
+ // TestTaskSmoke runs smoke tests with specified infrastructure providers.
23
+ // Cloud provider access credentials (provided as environment variables) are required.
24
+ func TestTaskSmoke (t * testing.T ) {
25
25
testName := os .Getenv ("SMOKE_TEST_IDENTIFIER" )
26
26
sweepOnly := os .Getenv ("SMOKE_TEST_SWEEP" ) != ""
27
27
You can’t perform that action at this time.
0 commit comments