| Start |
|---|
| Defining Factories If you have a ActiveRecord User class with name and email attributes, you could create a factory for it by making the FactoryGirl guess it: Or you can make it explicit and even change its name: Then in your spec you can use the FactoryGirl's methods with these, like this: The most common methods are: |
Read Article
https://develop.horje.com/learn/1434/reference