-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ensuring that the wizards buttons travers in the same order forwards …
…and backwards (#1728) * testing the wizard in reverse order * rubocop 🚨 * Make sure the wizard buttons are a mirror image in forward and reverse * ensuring that the wizards buttons travers in the same order forwards and backwards --------- Co-authored-by: Carolyn Cole <cac9@princeton.edu>
- Loading branch information
1 parent
d876ab3
commit 1f4e14e
Showing
5 changed files
with
53 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# frozen_string_literal: true | ||
require "rails_helper" | ||
|
||
describe "walk the wizard in reverse", type: :system, js: true do | ||
it "follow the same path in reverse or forward" do | ||
work = FactoryBot.create :draft_work, files_location: "file_upload" | ||
stub_s3 data: [FactoryBot.build(:s3_readme, work:)] | ||
sign_in work.created_by_user | ||
visit work_review_path(work) | ||
|
||
expect(page).to have_content "Data curators will review" | ||
click_on "Go Back" | ||
|
||
expect(page).to have_content "Once you have uploaded" | ||
click_on "Go Back" | ||
|
||
expect(page).to have_content "Begin the process to upload your submission" | ||
click_on "Go Back" | ||
|
||
expect(page).to have_content "Please upload the README" | ||
click_on "Go Back" | ||
|
||
expect(page).to have_content "By initiating this new submission" | ||
click_on "Save Work" | ||
|
||
expect(page).to have_content "Please upload the README" | ||
click_on "Continue" | ||
|
||
expect(page).to have_content "Begin the process to upload your submission" | ||
click_on "Continue" | ||
|
||
expect(page).to have_content "Once you have uploaded" | ||
click_on "Continue" | ||
|
||
expect(page).to have_content "Data curators will review" | ||
end | ||
end |