Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing errors when the fixture file is referencing a missing column is obtuse #21201

Closed
dhh opened this issue Aug 11, 2015 · 3 comments
Closed
Assignees
Milestone

Comments

@dhh
Copy link
Member

dhh commented Aug 11, 2015

Here's the error I got from having an extra, since-removed column mentioned in a yml fixture:

 30) Error:
RecurrenceScheduleTest#test_every_Friday_morning:
NoMethodError: undefined method `sql_type' for nil:NilClass

Ouch. We can do better than that.

@dhh dhh added this to the 5.0.0 milestone Aug 11, 2015
@senny
Copy link
Member

senny commented Aug 13, 2015

@dhh yea, this was more expressive in earlier versions. I'll have a look.

@senny senny self-assigned this Aug 13, 2015
@senny
Copy link
Member

senny commented Aug 13, 2015

Changed it to raise an ActiveRecord::FixtureError:

ActiveRecord::Fixture::FixtureError: table "parrots" has no column named "arrr"

@senny senny closed this as completed in e50fe85 Aug 13, 2015
@dhh
Copy link
Member Author

dhh commented Aug 13, 2015

Awesome! Thanks!

On Thu, Aug 13, 2015 at 10:16 AM, Yves Senn notifications@github.com
wrote:

Closed #21201 #21201 via e50fe85
e50fe85
.


Reply to this email directly or view it on GitHub
#21201 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants