title: FactoryGirl doesn't update counter field for associated object
body: <pre><code>class Topic &lt; ActiveRecord::Base
    belongs_to :success_criterion
  end
  
  class SuccessCriterion &lt; ActiveRecord::Base
    has_many :topics, dependent: :restrict_with_error
  end
  </code></pre>
  
  <p><code>SuccessCriterion</code> manages a <code>topics_counter</code> counter, but it doesn't seem to be updated when using the following factory:</p>
  
  <pre><code>FactoryGirl.define do
    factory :topic do
      success_criterion { create(:success_criterion) }
      title             'Topic test title'
      intro             'Topic test intro'
      outro             'Topic test outro'
    end
  end
  </code></pre>
  
  <p>Take a look at the following:</p>
  
  <pre><code>@topic             = create :topic
  @success_criterion = @topic.success_criterion
  
  @success_criterion.topics.any?
  =&gt; false
  @success_criterion.topics_count
  =&gt; 0
  @success_criterion.topics.count
  =&gt; 1
  </code></pre>
  
  <p>What's happening here? Without the <code>topics_counter</code> field, it works as expected, so it seems the FactoryGirl doesn't seem to update the counter when doing <code>success_criterion { create(:success_criterion) }</code>.</p>