Permalink
Commits on Feb 12, 2018
  1. release-3.0.5

    chrisarcand committed Feb 12, 2018
  2. Merge pull request #73 from chrisarcand/fix-regression

    chrisarcand committed Feb 12, 2018
    Fix regression w/ writer and no reader
Commits on Feb 11, 2018
  1. Fix regression w/ writer and no reader

    chrisarcand committed Feb 11, 2018
    According to the README, this behavior is expected:
    https://github.com/FooBarWidget/default_value_for/tree/1d1b2592eb00741a290d8406353846ddd8aae335#attributes-that-arent-database-columns
    
    However, it fails after 6f83fd6
    
    This change allows all three types of scenarios that are expected:
    
    * Normal attributes (usually backed by columns)
    * Attributes not found within the attributes hash (ex: ActiveRecord::Store) but are accessed via a reader
    * Attributes with *only* a writer and no reader (as in the README link above)
Commits on Feb 3, 2018
  1. release-3.0.4

    chrisarcand committed Feb 3, 2018
  2. Merge pull request #63 from culturecode/master

    chrisarcand committed Feb 3, 2018
    Fix stored attributes + allows_nil => false
Commits on Jan 17, 2018
  1. Merge pull request #1 from FooBarWidget/master

    rywall committed Jan 17, 2018
    Rails 5 support
Commits on Jul 3, 2017
  1. Bump version

    norman committed Jul 3, 2017
  2. Merge pull request #64 from chrisarcand/rails-5-1

    norman committed Jul 3, 2017
    Add Rails 5.1 support
Commits on May 3, 2017
  1. Use assert_nil

    chrisarcand committed May 3, 2017
    Removes deprecation warning in tests
  2. Support Rails 5.1

    chrisarcand committed May 3, 2017
  3. Fix Rakefile

    chrisarcand committed May 3, 2017
    Since utilizing Appraisal, these tasks aren't really necessary; but
    let's update them anyway in case you really don't want to use Appraisal.
  4. Ignore .bundle config

    chrisarcand committed May 3, 2017
    This can be checked in or ignored but certainly not be present and
    untracked.
Commits on Dec 16, 2016
  1. Fix stored attributes + allows_nil => false

    njakobsen committed Dec 16, 2016
    Fix bug that prevented default value from working when a value was passed in at initialization, and `:allows_nil => false`. Only the attributes hash was being read, so stored attributes were not being detected.
    
    Closes #59.
Commits on Jul 12, 2016
  1. Bump version and give credit

    norman committed Jul 12, 2016
  2. Merge pull request #57 from matthewd/rails-50

    norman committed Jul 12, 2016
    Add Rails 5.0 support
Commits on Jan 7, 2016
  1. Ignore change-tracking for unknown attributes

    matthewd committed Jan 6, 2016
    In Rails 5.0, we can only clear changes to real AMo/AR attributes -- not
    other setters we happen to be invoking.
Commits on Jan 5, 2016
  1. Merge pull request #56 from agios/concurrency

    FooBarWidget committed Jan 5, 2016
    Fix for concurrency
  2. Fix for concurrency

    agios committed Jan 5, 2016
  3. Merge pull request #55 from seanhussey/patch-1

    FooBarWidget committed Jan 5, 2016
    Just fixing a small typo.
Commits on Dec 14, 2015
  1. Just fixing a small typo.

    seanhussey committed Dec 14, 2015
Commits on Dec 15, 2014
  1. Invoke ActiveSupport::Dependencies.clear after test runs

    norman committed Dec 15, 2014
    On Rails 4.1+, depending on the order the tests run in, the Book class
    created during test setup will sometimes be resolved to the same class
    used by a previous test method, even though the constant it was assigned
    to has been unset. This is because the class is still assigned
    anonymously as the value to the "Book" key in an instance of
    ActiveSupport::Dependencies::ClassCache.
    
    You can see this symptom by checking out the previous commit and
    running:
    
      BUNDLE_GEMFILE=gemfiles/Rails_42.gemfile bundle exec ruby  -e 'require "./test.rb"' -- --seed 43 -n "/^(?:DefaultValuePluginTest#(?:test_works_with_nested_attributes|test_can_specify_default_value_via_association))$/"
    
    Explicitly clearing the cache resolves this issue.
    
    See #47
    See #46
  2. Fix setting defaults for nested attributes

    norman committed Dec 15, 2014
    Resolves #16
  3. Update comments

    norman committed Dec 15, 2014
  4. Rename test for clarity

    norman committed Dec 15, 2014
  5. Handle AR 3 version and feature setup more precisely

    norman committed Dec 15, 2014
    AR < 4 now always means >= 3.2.0, and we can always assume the
    :without_protection option is supported.
  6. Spacing

    norman committed Dec 15, 2014
  7. Remove "define_model_class" from test

    norman committed Dec 15, 2014
    Use the real model classes instead.