Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Commits on Aug 11, 2012
  1. Erik Ostrom Joshua Clayton

    Fixed reference to "stub" build strategy.

    eostrom authored joshuaclayton committed
Commits on Aug 3, 2012
  1. Joshua Clayton

    Bump version to 4.0.0

    joshuaclayton authored
Commits on Aug 2, 2012
  1. Joshua Clayton
  2. Joshua Clayton

    Prep for FactoryGirl 4.0

    joshuaclayton authored
  3. Joshua Clayton

    Bump version to 3.6.1

    joshuaclayton authored
  4. Joshua Clayton
  5. Joshua Clayton
  6. Joshua Clayton
  7. Joshua Clayton
  8. Joshua Clayton
Commits on Jul 27, 2012
  1. Joshua Clayton

    Bump version to 3.6.0

    joshuaclayton authored
  2. Joshua Clayton
  3. αλεx π Joshua Clayton

    Adding JRuby support to FactoryGirl

    ifesdjeen authored joshuaclayton committed
      JRuby are affected by inconsistent behavior of overriding
      #respond_to? that is causing an unconditional call to
      #respond_to_missing.
    
      Current change does not affect MRI users in any way,
      JRuby-specific things are wrapped into the RUBY_PLATFORM
      check.
    
      Adding docs, modifying gemspec and travis.yml to make factory_girl to pass on Travis.
    
      Wire up tests
  4. Joshua Clayton
  5. Joshua Clayton
Commits on Jul 25, 2012
  1. Joshua Clayton
Commits on Jul 24, 2012
  1. Joshua Clayton
Commits on Jul 14, 2012
  1. Prem Sichanugrist Joshua Clayton

    Fix FactoryGirl naming convention

    sikachu authored joshuaclayton committed
    So now, we'll always refer to this Gem as FactoryGirl, regardless of
    context. This commit is to make it consistence throughout the code base.
Commits on Jul 12, 2012
  1. Joshua Clayton

    Add DefinitionHierarchy to handle inheritance of some definition attr…

    joshuaclayton authored
    …ibutes
    
    This includes #callbacks, #constructor, and #to_create. The reasoning
    behind this is that we were mimicing an inheritance chain via methods;
    now, we actually generate classes, which Factory maintains, who inherit
    from their parent's hierarchy. We build the hierarchy during compilation
    to conditionally define methods based on whether what we're dealing
    with from the definition is actually meaningful. The base class
    (DefinitionHierarchy) uses the defaults (an empty array for #callbacks
    and the global #to_create and #constructor) so once we hit the top
    level, if the definition doesn't set any overrides, we have a list of
    sensible values.
Commits on Jul 7, 2012
  1. Joshua Clayton
Commits on Jun 29, 2012
  1. Joshua Clayton

    Allow factories with traits to be used in associations

    joshuaclayton authored
    This allows defining associations with factories using traits by slicing
    up the hash passed to association. Passing an array to `:factory` will
    use the first item in the array as the factory, with any subsequent
    symbols as traits.
    
    Here's an example:
    
        factory :post do
          association :author, factory: [:user, :admin], name: 'John Doe'
        end
    
    Closes #395
Commits on Jun 25, 2012
  1. Joshua Clayton
  2. Joshua Clayton
Commits on Jun 22, 2012
  1. Joshua Clayton
  2. Joshua Clayton

    Bump version to 3.5.0

    joshuaclayton authored
  3. Joshua Clayton
  4. Joshua Clayton
Commits on Jun 20, 2012
  1. Joshua Clayton

    Fix date in NEWS

    joshuaclayton authored
  2. Joshua Clayton

    Bump version to 3.4.2

    joshuaclayton authored
  3. Joshua Clayton
Commits on Jun 19, 2012
  1. Joshua Clayton
Commits on Jun 18, 2012
  1. Joshua Clayton

    Bump version to 3.4.1

    joshuaclayton authored
Commits on Jun 16, 2012
  1. Joshua Clayton

    Fix various trait bugs so traits can be used within each other

    joshuaclayton authored
    The previous implementation of trait handling within the Definition
    didn't account for when implicit traits were used within other traits.
    This is useful if you have two different traits, but one depends on
    another; for example, a refunded order and a completed order could both
    have the attribute `completed_at` set, but refunded would additionally
    have `refunded_at` set:
    
        FactoryGirl.define do
          factory :order do
            trait :completed do
              completed_at { 3.days.ago }
            end
    
            trait :refunded do
              completed
              refunded_at { 1.day.ago }
            end
          end
        end
    
    This also tests to make sure that callbacks, custom constructors, and
    creation overrides work correctly when implicit traits are used within
    other traits.
    
    Fixes #360
Commits on Jun 12, 2012
  1. Joshua Clayton

    Don't mutate hash

    joshuaclayton authored
Commits on Jun 11, 2012
  1. Joshua Clayton

    Bump version to 3.4.0

    joshuaclayton authored
Something went wrong with that request. Please try again.