1
0
Fork 0
mirror of https://github.com/thoughtbot/factory_bot.git synced 2022-11-09 11:43:51 -05:00
Commit graph

6 commits

Author SHA1 Message Date
Avielle
c716ce01b4 Replace 'girl' with 'bot' everywhere (#1051)
Also: add a deprecation warning to factory_girl, asking users to switch to
factory_bot

https://github.com/thoughtbot/factory_girl/issues/921
2017-10-20 15:20:28 -04:00
Daniel Colson
5e6f018c58 Pass evaluator to to_create (#1036) 2017-09-28 08:17:17 -04:00
Joshua Clayton
f7efc610fd Allow to_create defined for all factories
This allows users to define to_create for every factory run through
factory_girl.

    FactoryGirl.define do
      to_create {|instance| instance.persist! }
    end

If you want to override this default, set it per factory or in a trait
(and include the trait).

Closes #341
2012-05-12 18:10:02 -04:00
Joshua Clayton
645afa9689 Fix to_create so it works when defined in a trait 2012-05-11 10:52:19 -04:00
Joshua Clayton
7234f9f07e Style cleanup 2012-05-05 01:14:21 -04:00
Joshua Clayton
89d5e944d5 Refactor Strategies
This changes Strategy from a class to a module and removes inheritance.
It introduces an Evaluation facade to make building strategies easier
2012-04-13 17:20:02 -04:00