Skip to content

Commit

Permalink
Fix codeclimate suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
taitus committed Dec 17, 2017
1 parent 6560086 commit 83dff0c
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
2 changes: 1 addition & 1 deletion spec/features/admin/passwords_specs.rb
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@

context 'Lobby' do
background do
@lobby = create(:user, :lobby)
@lobby = create(:user, :lobby)
login_as(@lobby)
visit edit_password_path(@lobby)
end
Expand Down
34 changes: 17 additions & 17 deletions spec/features/organizations_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -308,26 +308,26 @@
end

scenario "Should display organizations with event with lobby_activity", :search do
organization_one = create(:organization, entity_type: :lobby, name: "Organizacion 1")
organization_two = create(:organization, entity_type: :lobby, name: "No lobby activity")
event=create(:event,organization: organization_one)
event.lobby_activity = true
event.event_agents << create(:event_agent)
event.save!
event_two = create(:event, lobby_activity: false, organization: organization_two)
event_two.lobby_activity = false
event_two.event_agents << create(:event_agent)
event_two.save!
Organization.reindex
organization_one = create(:organization, entity_type: :lobby, name: "Organizacion 1")
organization_two = create(:organization, entity_type: :lobby, name: "No lobby activity")
event=create(:event,organization: organization_one)
event.lobby_activity = true
event.event_agents << create(:event_agent)
event.save!
event_two = create(:event, lobby_activity: false, organization: organization_two)
event_two.lobby_activity = false
event_two.event_agents << create(:event_agent)
event_two.save!
Organization.reindex

visit organizations_path
visit organizations_path

find(:css, "#lobby_activity[value='1']").set(true)
click_button(I18n.t('main.form.search'))
find(:css, "#lobby_activity[value='1']").set(true)
click_button(I18n.t('main.form.search'))

expect(page).to have_content "Organizacion 1"
expect(page).not_to have_content "No lobby activity"
end
expect(page).to have_content "Organizacion 1"
expect(page).not_to have_content "No lobby activity"
end

scenario 'Should be go to show page when click on organization', :search do
organization = create(:organization)
Expand Down

0 comments on commit 83dff0c

Please sign in to comment.