Change single quotes to double quotes

This commit is contained in:
Julian Herrero
2019-02-01 16:48:49 +01:00
parent 4a12425987
commit 31ac8b7f55
302 changed files with 6403 additions and 6403 deletions

View File

@@ -1,6 +1,6 @@
require 'rails_helper'
require "rails_helper"
feature 'Admin::Organizations' do
feature "Admin::Organizations" do
background do
administrator = create(:user)
@@ -89,13 +89,13 @@ feature 'Admin::Organizations' do
visit admin_organizations_path
within("#organization_#{organization.id}") do
expect(page).to have_current_path(admin_organizations_path, ignore_query: true)
expect(page).to have_link('Verify')
expect(page).to have_link('Reject')
expect(page).to have_link("Verify")
expect(page).to have_link("Reject")
click_on 'Verify'
click_on "Verify"
end
expect(page).to have_current_path(admin_organizations_path, ignore_query: true)
expect(page).to have_content 'Verified'
expect(page).to have_content "Verified"
expect(organization.reload.verified?).to eq(true)
end
@@ -108,17 +108,17 @@ feature 'Admin::Organizations' do
click_on "Verified"
within("#organization_#{organization.id}") do
expect(page).to have_content 'Verified'
expect(page).not_to have_link('Verify')
expect(page).to have_link('Reject')
expect(page).to have_content "Verified"
expect(page).not_to have_link("Verify")
expect(page).to have_link("Reject")
click_on 'Reject'
click_on "Reject"
end
expect(page).to have_current_path(admin_organizations_path, ignore_query: true)
expect(page).not_to have_content organization.name
click_on 'Rejected'
expect(page).to have_content 'Rejected'
click_on "Rejected"
expect(page).to have_content "Rejected"
expect(page).to have_content organization.name
expect(organization.reload.rejected?).to eq(true)
@@ -131,14 +131,14 @@ feature 'Admin::Organizations' do
click_on "Rejected"
within("#organization_#{organization.id}") do
expect(page).to have_link('Verify')
expect(page).not_to have_link('Reject', exact: true)
expect(page).to have_link("Verify")
expect(page).not_to have_link("Reject", exact: true)
click_on 'Verify'
click_on "Verify"
end
expect(page).to have_current_path(admin_organizations_path, ignore_query: true)
expect(page).not_to have_content organization.name
click_on('Verified')
click_on("Verified")
expect(page).to have_content organization.name
@@ -147,34 +147,34 @@ feature 'Admin::Organizations' do
scenario "Current filter is properly highlighted" do
visit admin_organizations_path
expect(page).not_to have_link('Pending')
expect(page).to have_link('All')
expect(page).to have_link('Verified')
expect(page).to have_link('Rejected')
expect(page).not_to have_link("Pending")
expect(page).to have_link("All")
expect(page).to have_link("Verified")
expect(page).to have_link("Rejected")
visit admin_organizations_path(filter: 'all')
expect(page).not_to have_link('All')
expect(page).to have_link('Pending')
expect(page).to have_link('Verified')
expect(page).to have_link('Rejected')
visit admin_organizations_path(filter: "all")
expect(page).not_to have_link("All")
expect(page).to have_link("Pending")
expect(page).to have_link("Verified")
expect(page).to have_link("Rejected")
visit admin_organizations_path(filter: 'pending')
expect(page).to have_link('All')
expect(page).not_to have_link('Pending')
expect(page).to have_link('Verified')
expect(page).to have_link('Rejected')
visit admin_organizations_path(filter: "pending")
expect(page).to have_link("All")
expect(page).not_to have_link("Pending")
expect(page).to have_link("Verified")
expect(page).to have_link("Rejected")
visit admin_organizations_path(filter: 'verified')
expect(page).to have_link('All')
expect(page).to have_link('Pending')
expect(page).not_to have_link('Verified')
expect(page).to have_link('Rejected')
visit admin_organizations_path(filter: "verified")
expect(page).to have_link("All")
expect(page).to have_link("Pending")
expect(page).not_to have_link("Verified")
expect(page).to have_link("Rejected")
visit admin_organizations_path(filter: 'rejected')
expect(page).to have_link('All')
expect(page).to have_link('Pending')
expect(page).to have_link('Verified')
expect(page).not_to have_link('Rejected')
visit admin_organizations_path(filter: "rejected")
expect(page).to have_link("All")
expect(page).to have_link("Pending")
expect(page).to have_link("Verified")
expect(page).not_to have_link("Rejected")
end
scenario "Filtering organizations" do
@@ -182,37 +182,37 @@ feature 'Admin::Organizations' do
create(:organization, :rejected, name: "Rejected Organization")
create(:organization, :verified, name: "Verified Organization")
visit admin_organizations_path(filter: 'all')
expect(page).to have_content('Pending Organization')
expect(page).to have_content('Rejected Organization')
expect(page).to have_content('Verified Organization')
visit admin_organizations_path(filter: "all")
expect(page).to have_content("Pending Organization")
expect(page).to have_content("Rejected Organization")
expect(page).to have_content("Verified Organization")
visit admin_organizations_path(filter: 'pending')
expect(page).to have_content('Pending Organization')
expect(page).not_to have_content('Rejected Organization')
expect(page).not_to have_content('Verified Organization')
visit admin_organizations_path(filter: "pending")
expect(page).to have_content("Pending Organization")
expect(page).not_to have_content("Rejected Organization")
expect(page).not_to have_content("Verified Organization")
visit admin_organizations_path(filter: 'verified')
expect(page).not_to have_content('Pending Organization')
expect(page).not_to have_content('Rejected Organization')
expect(page).to have_content('Verified Organization')
visit admin_organizations_path(filter: "verified")
expect(page).not_to have_content("Pending Organization")
expect(page).not_to have_content("Rejected Organization")
expect(page).to have_content("Verified Organization")
visit admin_organizations_path(filter: 'rejected')
expect(page).not_to have_content('Pending Organization')
expect(page).to have_content('Rejected Organization')
expect(page).not_to have_content('Verified Organization')
visit admin_organizations_path(filter: "rejected")
expect(page).not_to have_content("Pending Organization")
expect(page).to have_content("Rejected Organization")
expect(page).not_to have_content("Verified Organization")
end
scenario "Verifying organization links remember the pagination setting and the filter" do
per_page = Kaminari.config.default_per_page
(per_page + 2).times { create(:organization) }
visit admin_organizations_path(filter: 'pending', page: 2)
visit admin_organizations_path(filter: "pending", page: 2)
click_on('Verify', match: :first)
click_on("Verify", match: :first)
expect(current_url).to include('filter=pending')
expect(current_url).to include('page=2')
expect(current_url).to include("filter=pending")
expect(current_url).to include("page=2")
end
end