method
new
rails latest stable - Class:
ActiveRecord::FixtureSet::TableRows
new(table_name, model_class:, fixtures:)public
No documentation available.
# File activerecord/lib/active_record/fixture_set/table_rows.rb, line 9
def initialize(table_name, model_class,, fixtures))
@model_class = model_class
# track any join tables we need to insert later
@tables = Hash.new { |h, table| h[table] = [] }
# ensure this table is loaded before any HABTM associations
@tables[table_name] = nil
build_table_rows_from(table_name, fixtures)
end