I have set up my rails app to use Neo4j using Neo4jRB which fine both in production and development. In testing however I get the error ActiveRecord::StatementInvalid: SQLite3::SQLException: no such table:
for each test, so it seems as though it still wants to use SQLite3.
I have set up my config/neo4j.yml so that it points to a running test database, however database.yml still points to SQLite3 and if I make changes to that then the error changes, so I'm guessing it has to do with that, but the neo4jrb
documentation doesn't mention that you need to change database.yml.
Here's the test section of my neo4j.yml:
test:
type: http
url: http://localhost:7575
database.yml is just the standard Rails generated file:
default: &default
adapter: sqlite3
pool: <%= ENV.fetch(RAILS_MAX_THREADS") { 5 } %>
timeout: 5000
test:
<<: *default
database: db/test.sqlite3
Changing the adapter to for instance neo4jrb
in database.yml removes the SQLite exceptions and gives me an adapter not found exception instead.