Using assert.Regexp for testing stderr's content
This commit is contained in:
parent
81caade918
commit
793e866850
1 changed files with 1 additions and 1 deletions
|
|
@ -439,7 +439,7 @@ func Test_loginRun_Survey(t *testing.T) {
|
|||
if tt.wantErrOut == nil {
|
||||
assert.Equal(t, "", stderr.String())
|
||||
} else {
|
||||
assert.True(t, tt.wantErrOut.MatchString(stderr.String()))
|
||||
assert.Regexp(t, tt.wantErrOut, stderr.String())
|
||||
}
|
||||
reg.Verify(t)
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue