title: Any way to DRY this FactoryGirl example?
body: <p>I have the following factory:</p>
  
  <pre><code>FactoryGirl.define do
    factory :user do
      name 'Name'
      password 'password'
      email 'email@example.com'
    end
  end
  </code></pre>
  
  <p>I have the following code in <code>before</code> block (I am creating all possible variations of <code>email</code>-<code>some_boolean_flag</code> pairs where email can take <code>''</code> and default value and some_boolean_flag can be false/nil or true):</p>
  
  <pre><code>FactoryGirl.create(:user, email: '', some_boolean_flag: false)
  FactoryGirl.create(:user, email: '', some_boolean_flag: true)
  FactoryGirl.create(:user, some_boolean_flag: nil)
  FactoryGirl.create(:user, some_boolean_flag: true)
  </code></pre>
  
  <p>How can I DRY it? Is there any way in FactoryGirl to create a list of objects but with specific attributes being different and without repeating same line over and over? Thanks!</p>