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

Update README.md #1

Merged
merged 1 commit into from Mar 26, 2017
Merged

Update README.md #1

merged 1 commit into from Mar 26, 2017

Conversation

@mgrachev
Copy link
Contributor

@mgrachev mgrachev commented Jan 1, 2017

You can define a schematic for generating objects by defining Fabricators as spec/fabricators/**/*fabricator.rb.

Source: https://github.com/paulelliott/fabrication-site/blob/master/source/index.markdown

@mgrachev
Copy link
Contributor Author

@mgrachev mgrachev commented Mar 26, 2017

@jodosha What do you think about it?

@jodosha
Copy link
Owner

@jodosha jodosha commented Mar 26, 2017

@mgrachev Thank you for this PR.


I agree with the name of the file but not with the path.

In new Hanami projects, we generate a spec_helper.rb that automatically requires all the files under spec/support. See https://github.com/hanami/hanami/blob/master/lib/hanami/generators/application/container/spec_helper.rb.rspec.tt

So, if you put your fabricators under that directory (eg spec/support/fabricators), you don't need to require them manually.

Copy link
Owner

@jodosha jodosha left a comment

Please leave under spec/support

@mgrachev
Copy link
Contributor Author

@mgrachev mgrachev commented Mar 26, 2017

@jodosha Done.

Copy link
Owner

@jodosha jodosha left a comment

LGTM 👍 Thank you!

@jodosha jodosha merged commit c8da094 into jodosha:master Mar 26, 2017
@mgrachev mgrachev deleted the mgrachev:feature/update-readme branch Mar 27, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants