The high-level API is implemented in Active Record. You do not need to
test via the logger, at the adapter level you only need to write
#explain, which should return a string[*], and test that very return
value. Just ensure the string itself is correct.
The caller code takes that string and does stuff with it, but that's
handled above and it's tested in Active Record itself in an agnostic
For example, this is the implementation in the SQLite adapter:
and these are its tests:
Your adapter should do something like that.
Remember also to define a predicate #supports_explain? that returns true.
Hope that helps, please write again if more questions arise.
[*] This string should ideally be a carbon copy of the one users are
familiar with. I don't know if that makes sense for SQL Server, maybe
they are used to some GUI output there?