Hi. I am using postgresql.
Now I wanted to use unit_record to speed up my tests. However I realise that it fails with
NoMethodError: undefined method `indexes' for #ActiveRecord::ConnectionAdapters::UnitRecordAdapter:0x7fa18f27ba90
It seems like the postgresql_adapter implements this method, and it is called when invoking ActiveRecord::Base#Count
However If I monkeypatch like this (in unit_test_helper.rb)
class ActiveRecord::ConnectionAdapters::UnitRecordAdapter
def indexes(table_name, name = nil)
[]
end
end
I get the correct behaviour "RuntimeError: ActiveRecord is disconnected; database access is unavailable in unit tests."