Merge pull request #479 from AyuntamientoMadrid/orgs-responsible
Orgs responsible
This commit is contained in:
@@ -9,6 +9,7 @@ feature 'Organizations' do
|
||||
visit new_organization_registration_path
|
||||
|
||||
fill_in 'user_organization_attributes_name', with: 'Greenpeace'
|
||||
fill_in 'user_organization_attributes_responsible_name', with: 'Dorothy Stowe'
|
||||
fill_in 'user_email', with: 'green@peace.com'
|
||||
fill_in 'user_password', with: 'greenpeace'
|
||||
fill_in 'user_password_confirmation', with: 'greenpeace'
|
||||
|
||||
@@ -2,6 +2,16 @@ require 'rails_helper'
|
||||
|
||||
feature 'Verification path' do
|
||||
|
||||
scenario "User is an organization" do
|
||||
user = create(:user, verified_at: Time.now)
|
||||
create(:organization, user: user)
|
||||
|
||||
login_as(user)
|
||||
visit verification_path
|
||||
|
||||
expect(current_path).to eq account_path
|
||||
end
|
||||
|
||||
scenario "User is verified" do
|
||||
user = create(:user, verified_at: Time.now)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user