Use teardown helper method to ensure that SQLCounter.clear_log is called...

Related to https://github.com/rails/rails/pull/14332#discussion_r10416015