module ActiveGroonga::TestFixtures
Public Class Methods
included(base)
click to toggle source
# File lib/active_groonga/fixtures.rb, line 19 def included(base) base.class_eval do alias_method_chain :setup_fixtures, :active_groonga alias_method_chain :teardown_fixtures, :active_groonga end end
Public Instance Methods
load_active_groonga_fixtures()
click to toggle source
# File lib/active_groonga/fixtures.rb, line 40 def load_active_groonga_fixtures @loaded_fixtures ||= {} fixtures = Fixtures.create_fixtures(fixture_path, fixture_table_names, fixture_class_names) do ConnectionMock.new end unless fixtures.nil? if fixtures.instance_of?(Fixtures) @loaded_fixtures[fixtures.name] = fixtures else fixtures.each { |f| @loaded_fixtures[f.name] = f } end end end
setup_fixtures_with_active_groonga()
click to toggle source
# File lib/active_groonga/fixtures.rb, line 27 def setup_fixtures_with_active_groonga setup_fixtures_without_active_groonga @fixture_cache ||= {} @@already_loaded_fixtures ||= {} load_active_groonga_fixtures end
teardown_fixtures_with_active_groonga()
click to toggle source
# File lib/active_groonga/fixtures.rb, line 36 def teardown_fixtures_with_active_groonga teardown_fixtures_without_active_groonga end