In my development and test environments, I want to seed the database with a bunch of users. I\'m using Ruby on Rails v3.2.8 and the latest Devise. So I added this line in
The skip_confirmation method will only work if you have confirmable module in your user model, otherwise remove it.
skip_confirmation
confirmable
user = User.new( :email => "admin@xxxxx.xxx", :password => "123456", :password_confirmation => "123456" ) user.skip_confirmation! user.save!