■リレーションつけて、@student.interview_typeとかテスト内でやったら次のエラーがでた何で?
開発環境では動く。テストDBにもカラムはあるのに。という時に
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
3) Error: test_update(StudentTest): NoMethodError: undefined method `interview_types' for #<StudentTest:0x47602ec> c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.13.3/lib/action_controller/test_ process.rb:452:in `method_missing' ./test/unit/student_test.rb:12:in `setup_without_fixtures' c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/active_record/fixture s.rb:576:in `setup'
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
それは、fixtureのロードをしていないからですよ(笑)外部キーを使う場合、その対象は
「fixtures :interview_types」と、明示的にロードしておく必要がある