added email presence validation to openid
closes #1658 added test for openid fixed robocup offences written tests for email presence validation minor changes shifted omniauth callback tests to rspec controllers fixed linting bug minor changes minor changes
This commit is contained in:
parent
2df8adea69
commit
83053f4626
5 changed files with 62 additions and 1 deletions
15
spec/models/openid.rb
Normal file
15
spec/models/openid.rb
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
require 'spec_helper'
|
||||
|
||||
describe Openid do
|
||||
subject { create(:openid) }
|
||||
|
||||
describe 'validation' do
|
||||
it { is_expected.to validate_presence_of(:provider) }
|
||||
it { is_expected.to validate_presence_of(:uid) }
|
||||
it { is_expected.to validate_presence_of(:email) }
|
||||
end
|
||||
|
||||
describe 'association' do
|
||||
it { is_expected.to belong_to(:user) }
|
||||
end
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue