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

Having a property called "type" on your model causes make to fail #242

Closed
patocallaghan opened this issue Sep 7, 2016 · 3 comments
Closed

Comments

@patocallaghan
Copy link
Collaborator

patocallaghan commented Sep 7, 2016

If your model has a property on it called type it will cause make to fail (and presumably build too). Doing a git bisect it looks like this was introduced with this commit b015ef2 specifically with this line here b015ef2#diff-5f1855cb8ac1827c7ef28bcaacf20a4bR85

type: this.typeTransformFn(fixture.type || modelName),

I've added a failing test here to replicate it, adding a type property to the employee model.

image

@danielspaniel
Copy link
Collaborator

I just put the solution for this in the docs last night.
Check it out:
https://github.com/danielspaniel/ember-data-factory-guy#defining-factories

@patocallaghan
Copy link
Collaborator Author

Oh, sorry I missed that. I'll close this then.

@danielspaniel
Copy link
Collaborator

Oh well, yeah .. was kinda tricky to find that one.

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

No branches or pull requests

2 participants