Skip to content

Commit

Permalink
address some review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
craig65535 committed Oct 10, 2023
1 parent de3f626 commit a120f21
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions assert/assertions_test.go
Expand Up @@ -2857,6 +2857,8 @@ func Test_truncatingFormat(t *testing.T) {
}
}

// parseLabeledOutput does the inverse of labeledOutput - it takes a formatted
// output string and turns it back into a slice of labeledContent.
func parseLabeledOutput(output string) []labeledContent {
labelPattern := regexp.MustCompile(`^\t([^\t]*): *\t(.*)$`)
contentPattern := regexp.MustCompile(`^\t *\t(.*)$`)
Expand Down Expand Up @@ -2986,8 +2988,8 @@ func TestErrorIs(t *testing.T) {
}
for _, tt := range tests {
tt := tt
mockT := new(captureTestingT)
t.Run(fmt.Sprintf("ErrorIs(%#v,%#v)", tt.err, tt.target), func(t *testing.T) {
mockT := new(captureTestingT)
res := ErrorIs(mockT, tt.err, tt.target)
mockT.checkResultAndErrMsg(t, tt.result, res, tt.resultErrMsg)
})
Expand Down Expand Up @@ -3049,8 +3051,8 @@ func TestNotErrorIs(t *testing.T) {
}
for _, tt := range tests {
tt := tt
mockT := new(captureTestingT)
t.Run(fmt.Sprintf("NotErrorIs(%#v,%#v)", tt.err, tt.target), func(t *testing.T) {
mockT := new(captureTestingT)
res := NotErrorIs(mockT, tt.err, tt.target)
mockT.checkResultAndErrMsg(t, tt.result, res, tt.resultErrMsg)
})
Expand Down

0 comments on commit a120f21

Please sign in to comment.