database_cleaner/examples/lib/neo4j_models.rb

18 lines
298 B
Ruby
Raw Normal View History

2014-12-01 11:19:27 -05:00
require 'neo4j-core'
class Neo4jWidget < Neo4j::Node
def self.create!(*args)
create(*args)
end
def self.count
Neo4j::Session.query.match('n').pluck('COUNT(n)').first
2014-12-01 11:19:27 -05:00
end
end
class Neo4jWidgetUsingDatabaseOne < Neo4jWidget
end
class Neo4jWidgetUsingDatabaseTwo < Neo4jWidget
end