title: FactoryGirl cannot assign to a enum validated parameter
body: <p>I am using RSpec, FactoryGirl and ActiveRecord. The following test is not passing:</p>
  
  <pre><code>require 'spec_helper'
  describe User, type: :model do
      it "has a valid factory" do
              expect(FactoryGirl.create(:user)).to be_valid
      end
  end
  </code></pre>
  
  <p>I have the following error:</p>
  
  <pre><code>1) User has a valid factory
   Failure/Error: expect(FactoryGirl.create(:user)).to be_valid
   ActiveRecord::RecordInvalid:
     Validation failed: Role can't be blank
  </code></pre>
  
  <p>I also have the following model:</p>
  
  <pre><code>class User &lt; ActiveRecord::Base
    devise :database_authenticatable, :registerable,
       :recoverable, :rememberable, :trackable, :validatable
    enum role: [:admin, :student, :school]
    validates :role, presence: true
  end
  </code></pre>
  
  <p>And I have the following factory:</p>
  
  <pre><code>require 'faker'
  FactoryGirl.define do
      factory :user do
              sequence(:email) { |n| "person#{n}@example.com" }
              password Faker::Internet.password(8, 16)
              role :student
      end
  end
  </code></pre>
  
  <p>However, it passes if I remove the enums in the model:</p>
  
  <pre><code>class User &lt; ActiveRecord::Base
    devise :database_authenticatable, :registerable,
       :recoverable, :rememberable, :trackable, :validatable
    validates :role, presence: true
  end
  </code></pre>
  
  <p>I would like to keep the enum as there is only a set of strings that I would like to allow represent roles.</p>
  
  <p>I would appreciate information that will help me to merge FactoryGirl with the enum correctly.</p>