Skip to content

Commit

Permalink
Update debug logger tests to match on duration
Browse files Browse the repository at this point in the history
Signed-off-by: Garrett Thornburg <[email protected]>
  • Loading branch information
film42 committed Jan 31, 2019
1 parent 7d00f28 commit 1d48ee8
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions store_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -259,13 +259,8 @@ func (s *StoreSuite) TestDebugWith() {
s.store.DebugWith(logger).RawQuery("SELECT 1 + 1")
s.store.DebugWith(logger).RawExec("UPDATE foo SET bar = 1")

s.Equal(
queries,
[]string{
"kallax: Query: SELECT 1 + 1",
"kallax: Exec: UPDATE foo SET bar = 1",
},
)
s.Regexp("kallax: Query: \\(\\d+\\.\\d+.+\\) SELECT 1 \\+ 1", queries[0])
s.Regexp("kallax: Exec: \\(\\d+\\.\\d+.+\\) UPDATE foo SET bar = 1", queries[1])
}

func (s *StoreSuite) assertFound(rs ResultSet, expected ...string) {
Expand Down

0 comments on commit 1d48ee8

Please sign in to comment.