mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
2acec46577
Currently, `set_fixture_class` is only available using the `TestFixtures` concern and it is ignored for `rake db:fixtures:load`. Using the correct model class, it is possible for the fixture load to also load the associations from the YAML files (e.g., `:belongs_to` and `:has_many`).
8 lines
145 B
YAML
8 lines
145 B
YAML
_fixture:
|
|
model_class: Post
|
|
|
|
second_welcome:
|
|
author_id: 1
|
|
title: Welcome to the another weblog
|
|
body: It's really nice today
|
|
type: Post
|