Skip to content

Commit

Permalink
Update step names
Browse files Browse the repository at this point in the history
  • Loading branch information
blacksmith-welder committed Sep 11, 2024
1 parent 251a954 commit 89eb6f4
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 28 deletions.
2 changes: 1 addition & 1 deletion staff_features/accessions/accession_create.feature
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Feature: Accession Create
Given an administrator user is logged in
Scenario: Accession is created
Given the user is on the New Accession page
When the user fills in Identifier
When the user fills in 'Identifier'
And the user clicks on 'Save'
Then the 'Accession created' message is displayed
Scenario: Accession is not created because required fields are missing
Expand Down
2 changes: 1 addition & 1 deletion staff_features/accessions/accession_delete.feature
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Feature: Accession Delete
When the user clicks on 'Browse'
And the user clicks on 'Accessions'
And the user filters by text with the Accession title
And the user clicks on the checkbox of the Accession
And the user checks the checkbox of the Accession
And the user clicks on 'Delete'
And the user clicks on 'Delete Records'
Then the 'Records deleted' message is displayed
Expand Down
2 changes: 1 addition & 1 deletion staff_features/accessions/accessions_search.feature
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ Feature: Accessions Search
Given two Accessions have been created with a common keyword in their title
When the user filters by text with the common title keyword used by both Accessions
And the user clicks on 'Title'
Then the two Accessions are sorted by descending title
Then the two Accessions are displayed sorted by descending title
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
end
end

When 'the user clicks on the checkbox of the Accession' do
When 'the user checks the checkbox of the Accession' do
find('#multiselect-item').check
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Feature: Digital Object Create
Scenario: Digital Object is created
Given the user is on the New Digital Object page
When the user fills in 'Title' with 'Alabama: Mobile: Government Street [Cochran photos]'
And the user fills in Identifier
And the user fills in 'Identifier'
And the user clicks on 'Save'
Then the 'Digital Object' created message is displayed
Scenario: Digital Object is not created because required fields are missing
Expand Down
6 changes: 3 additions & 3 deletions staff_features/repositories/repository_create.feature
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ Feature: Repository Create
When the user clicks on 'System'
And the user clicks on 'Manage Repositories'
And the user clicks on 'Create Repository'
And the user fills in the Repository Short Name
And the user fills in the Repository Name
And the user fills in 'Repository Short Name'
And the user fills in 'Repository Name'
And the user clicks on 'Save'
Then the 'Repository Created' message is displayed
Scenario: Repository cannot be created from an archivist user
Given an archivist user is logged in
When the user clicks on 'System'
Then the dropdown menu does not have the Manage Repositories option
Then the 'Manage Repositories' option is not displayed in the dropdown menu
16 changes: 2 additions & 14 deletions staff_features/repositories/repository_create.rb
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
# frozen_string_literal: true

When 'the user fills in the Repository Short Name' do
@uuid = SecureRandom.uuid

fill_in 'Repository Short Name', with: "Repository Short Name #{@uuid}"
end

When 'the user fills in the Repository Name' do
@uuid = SecureRandom.uuid

fill_in 'Repository Name', with: "Repository Name #{@uuid}"
end

Then 'the dropdown menu does not have the Manage Repositories option' do
expect(page).to_not have_text 'Manage Repositories'
Then 'the {string} option is not displayed in the dropdown menu' do |string|
expect(page).to_not have_text string
end
6 changes: 4 additions & 2 deletions staff_features/shared/step_definitions.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@
end
end

When 'the user fills in Identifier' do
fill_in 'Identifier', with: @uuid
When 'the user fills in {string}' do |label|
@uuid = SecureRandom.uuid if @uuid.nil?

fill_in label, with: @uuid
end

When 'the user fills in {string} with {string}' do |label, value|
Expand Down
8 changes: 4 additions & 4 deletions staff_features/users/user_create.feature
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ Feature: User Create
When the user clicks on 'System'
And the user clicks on 'Manage Users'
And the user clicks on 'Create User'
And the user fills in the Username
And the user fills in the Full name
And the user fills in the Password
And the user fills in the Confirm password
And the user fills in 'Username'
And the user fills in 'Full name'
And the user fills in 'Password'
And the user fills in 'Confirm password'
And the user clicks on 'Create Account'
Then the 'User Created' message is displayed
Scenario: User is not created because required fields are missing
Expand Down

0 comments on commit 89eb6f4

Please sign in to comment.