Skip to content
This repository has been archived by the owner on Aug 30, 2023. It is now read-only.

Commit

Permalink
Don't use testing.Run for backcompat
Browse files Browse the repository at this point in the history
  • Loading branch information
martinxsliu committed Jan 23, 2018
1 parent 5524c4d commit 5ca3e67
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions stacktrace_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -216,12 +216,10 @@ func TestCauseWithStacktrace(t *testing.T) {
{"pkg error wrapped thrice", pkgWrapped3, pkgErr},
}

for _, testCase := range testCases {
t.Run(testCase.name, func(t *testing.T) {
cause := causeWithStacktrace(testCase.inputErr)
if cause != testCase.expectedCause {
t.Errorf("expected %v; got %v", testCase.expectedCause, cause)
}
})
for _, tc := range testCases {
cause := causeWithStacktrace(tc.inputErr)
if cause != tc.expectedCause {
t.Errorf("for %s: expected %v; got %v", tc.name, tc.expectedCause, cause)
}
}
}

0 comments on commit 5ca3e67

Please sign in to comment.