How to convert errors_on to RSpec 3 syntax?
Looks like it exists in rspec-collection_matchers. Also from this issue you can monkey patch it.
If you don't want to bundle another gem, you can call valid?
on the test subject and then access the errors
array:
require 'spec_helper'
describe User, type: :model do
it 'is invalid without a password' do
user = FactoryGirl.build(:user, password: nil)
user.valid?
expect(user.errors[:password].size).to eq(1)
end
end