mirror of
https://github.com/ENSL/ensl.org.git
synced 2024-11-15 01:11:23 +00:00
Add SteamID range spec
This commit is contained in:
parent
07a22ce0f3
commit
a52ce6fb9a
1 changed files with 9 additions and 0 deletions
9
spec/features/users/user_signs_up_spec.rb
Normal file → Executable file
9
spec/features/users/user_signs_up_spec.rb
Normal file → Executable file
|
@ -43,6 +43,15 @@ feature 'Visitor signs up', js: :true do
|
|||
expect(page).to have_content(error_message('steamid.invalid'))
|
||||
end
|
||||
|
||||
scenario 'with out of range Steam ID' do
|
||||
within registration_form do
|
||||
fill_form(:user, user.slice(*sign_up_attributes).merge({ steamid: "0:0:2147483648" }))
|
||||
click_button submit(:user, :create)
|
||||
end
|
||||
|
||||
expect(page).to have_content(error_message('steamid.invalid'))
|
||||
end
|
||||
|
||||
def sign_up_attributes
|
||||
[:username, :email, :raw_password, :steamid]
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue