File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -235,7 +235,7 @@ func TestValidateFormType(t *testing.T) {
235235 },
236236 }
237237
238- t .Run ("TabledTests" , func (t * testing.T ) {
238+ passed := t .Run ("TabledTests" , func (t * testing.T ) {
239239 // TabledCases runs through all the manual test cases
240240 for _ , c := range cases {
241241 t .Run (c .name , func (t * testing.T ) {
@@ -251,6 +251,12 @@ func TestValidateFormType(t *testing.T) {
251251 }
252252 })
253253
254+ if ! passed {
255+ // Do not run additional tests and pollute the output
256+ t .Log ("Tests failed, will not run the assumed error cases" )
257+ return
258+ }
259+
254260 // AssumeErrorCases assumes any uncovered test will return an error.
255261 // This ensures all valid test case paths are covered.
256262 t .Run ("AssumeErrorCases" , func (t * testing.T ) {
You can’t perform that action at this time.
0 commit comments