Skip to content

Commit e47e3a2

Browse files
resurrect upload request specs & fix response codes
1 parent 39751be commit e47e3a2

16 files changed

+525
-422
lines changed

spec/config/browser.rb

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,23 +71,21 @@ def accepted_firefox_path
7171

7272

7373
RSpec.configure do |config|
74-
set_capybara_values
75-
7674
# Capybara.run_server = false
7775
Capybara.default_driver = :firefox
7876
Capybara.current_driver = :firefox
7977

8078

81-
config.before :all do
79+
config.before(:all, type: :feature) do
8280
set_capybara_values
8381
maximize_window_if_possible
8482
end
8583

86-
config.before :each do |example|
84+
config.before(:each, type: :feature) do |example|
8785
set_capybara_values
8886
end
8987

90-
config.after(:each) do |example|
88+
config.after(:each, type: :feature) do |example|
9189
unless example.exception.nil?
9290
take_screenshot screenshot_dir
9391
end

spec/features/shared/authorization_error.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
it "displays error" do
77
visit path
88
within(".modal") do
9-
expect(page).to have_css(".modal-header", text: "Request ERROR 500")
9+
expect(page).to have_css(".modal-header", text: "Request ERROR 403")
1010
expect(page).to have_css(".modal-body", text: "System-admin scope required")
1111
end
1212
end

spec/features/uploads_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
it "displays modal with authentication error" do
1515
visit path
1616
within(".modal") do
17-
expect(page).to have_css(".modal-header", text: "Request ERROR 500")
17+
expect(page).to have_css(".modal-header", text: "Request ERROR 403")
1818
expect(page).to have_css(".modal-body", text: "Sign-in required")
1919
end
2020
end

0 commit comments

Comments
 (0)