Skip to content

Commit

Permalink
Missing steps
Browse files Browse the repository at this point in the history
  • Loading branch information
blacksmith-welder committed Feb 6, 2025
1 parent 27ba352 commit b8e4001
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -204,3 +204,16 @@
And 'the user selects the Digital Object Component' do
click_on "Digital Object Component Label #{@uuid}"
end

Then 'the Assessment is linked to the Digital Object in the {string} form' do |form_title|
section_title = find('h3', text: form_title)
section = section_title.ancestor('section')
expect(section[:id]).to_not eq nil

related_accessions_elements = section.all('li.token-input-token')

expect(related_accessions_elements.length).to eq 1
related_accession = related_accessions_elements[0].find('.digital_object')

expect(related_accession[:'data-content']).to include "digital_objects/#{@digital_object_id}"
end
4 changes: 4 additions & 0 deletions staff_features/subjects/step_definitions/subject_shared.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
wait_for_ajax
end

Given 'the user is on the Subjects page' do
visit "#{STAFF_URL}/subjects"
end

Then 'the new Subject form has the following default values' do |form_values_table|
visit "#{STAFF_URL}/subjects/new"

Expand Down

0 comments on commit b8e4001

Please sign in to comment.