5656 name : go build
5757 run : go build -o terraform-plugin-dir/registry.terraform.io/RedisLabs/rediscloud/99.99.99/$(go env GOOS)_$(go env GOARCH)/terraform-provider-rediscloud .
5858
59+ go_unit_test :
60+ name : go unit test
61+ needs : [go_build]
62+ runs-on : ubuntu-latest
63+ steps :
64+ - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
65+ - uses : actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
66+ with :
67+ go-version-file : go.mod
68+ - run : go test ./... -run="^TestUnit" # Runs tests starting with TestUnit
69+
70+ tfproviderlint :
71+ name : tfproviderlint
72+ needs : [go_build]
73+ runs-on : ubuntu-latest
74+ steps :
75+ - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
76+ - uses : actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
77+ with :
78+ go-version-file : go.mod
79+ - run : make tfproviderlint
80+
5981 terraform_providers_schema :
6082 name : terraform providers schema
6183 needs : [go_build]
@@ -102,20 +124,21 @@ jobs:
102124 mkdir terraform-providers-schema
103125 terraform providers schema -json > terraform-providers-schema/schema.json
104126
105- go_test_smoke_aa_db :
106- name : go test smoke aa db
107- needs : [go_build]
127+ # All acceptance tests run in parallel after quick tests
128+ go_test_smoke_aa_tgw_attachment :
129+ name : go test smoke aa tgw attachment
130+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema]
108131 runs-on : ubuntu-latest
109132 steps :
110133 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
111134 - uses : actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
112135 with :
113136 go-version-file : go.mod
114- - run : EXECUTE_TESTS=true make testacc TESTARGS='-run="TestAccResourceRedisCloudActiveActiveDatabase_CRUDI "'
137+ - run : EXECUTE_TESTS=true make testacc TESTARGS='-run="TestAccResourceRedisCloudActiveActiveTransitGatewayAttachment_CRUDI "'
115138
116139 go_test_smoke_aa_enable_default_user :
117140 name : go test smoke aa enable default user
118- needs : [go_build ]
141+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
119142 runs-on : ubuntu-latest
120143 steps :
121144 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
@@ -124,20 +147,20 @@ jobs:
124147 go-version-file : go.mod
125148 - run : EXECUTE_TESTS=true make testacc TESTARGS='-run="TestAccResourceRedisCloudActiveActiveDatabase_enableDefaultUser"'
126149
127- go_test_smoke_aa_tgw_attachment :
128- name : go test smoke aa tgw attachment
129- needs : [go_build ]
150+ go_test_smoke_aa_db :
151+ name : go test smoke aa db
152+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
130153 runs-on : ubuntu-latest
131154 steps :
132155 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
133156 - uses : actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
134157 with :
135158 go-version-file : go.mod
136- - run : EXECUTE_TESTS=true make testacc TESTARGS='-run="TestAccResourceRedisCloudActiveActiveTransitGatewayAttachment_CRUDI "'
159+ - run : EXECUTE_TESTS=true make testacc TESTARGS='-run="TestAccResourceRedisCloudActiveActiveDatabase_CRUDI "'
137160
138161 go_test_smoke_essentials_sub :
139162 name : go test smoke essentials sub
140- needs : [go_build ]
163+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
141164 runs-on : ubuntu-latest
142165 steps :
143166 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
@@ -161,7 +184,7 @@ jobs:
161184
162185 go_test_smoke_pro_db :
163186 name : go test smoke pro db
164- needs : [go_build ]
187+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
165188 runs-on : ubuntu-latest
166189 steps :
167190 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
@@ -173,7 +196,7 @@ jobs:
173196
174197 go_test_smoke_misc :
175198 name : go test smoke misc
176- needs : [ go_build ]
199+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
177200 runs-on : ubuntu-latest
178201 steps :
179202 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
@@ -184,7 +207,7 @@ jobs:
184207
185208 go_test_pro_db_upgrade :
186209 name : go test smoke pro db upgrade
187- needs : [ go_build ]
210+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
188211 runs-on : ubuntu-latest
189212 steps :
190213 - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
@@ -195,7 +218,7 @@ jobs:
195218
196219 go_test_privatelink :
197220 name : go test smoke privatelink
198- needs : [ go_build ]
221+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
199222 runs-on : ubuntu-latest
200223 steps :
201224 - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
@@ -207,7 +230,7 @@ jobs:
207230
208231 go_test_block_public_endpoints :
209232 name : go test smoke public endpoints
210- needs : [ go_build ]
233+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
211234 runs-on : ubuntu-latest
212235 steps :
213236 - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
@@ -218,33 +241,11 @@ jobs:
218241
219242 go_test_smoke_qpf :
220243 name : go test smoke query performance factor
221- needs : [ go_build ]
244+ needs : [go_unit_test, tfproviderlint, terraform_providers_schema ]
222245 runs-on : ubuntu-latest
223246 steps :
224247 - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
225248 - uses : actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
226249 with :
227250 go-version-file : go.mod
228251 - run : EXECUTE_TESTS=true make testacc TESTARGS='-run="TestAccResourceRedisCloudProDatabase_qpf"'
229-
230- go_unit_test :
231- name : go unit test
232- needs : [go_build]
233- runs-on : ubuntu-latest
234- steps :
235- - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
236- - uses : actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
237- with :
238- go-version-file : go.mod
239- - run : go test ./... -run="^TestUnit" # Runs tests starting with TestUnit
240-
241- tfproviderlint :
242- name : tfproviderlint
243- needs : [go_build]
244- runs-on : ubuntu-latest
245- steps :
246- - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
247- - uses : actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
248- with :
249- go-version-file : go.mod
250- - run : make tfproviderlint
0 commit comments