Skip to content

Commit 974166f

Browse files
committed
changed rspec error for undefined method
1 parent c8119be commit 974166f

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

spec/search_spec.rb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,11 @@ def generate_test_object
3838
scenario 'empty search shows all results' do
3939
visit '/'
4040
click_button 'Search'
41-
expect(page).to have_content(
42-
'Search results for immigration records Last Name First Name Middle Name Age Gender Port Date Ship Destination'
43-
).and have_css('table#table tbody tr')
41+
expect(page).to satisfy do |current_page|
42+
current_page.has_content?(
43+
'Search results for immigration records Last Name First Name Middle Name Age Gender Port Date Ship Destination'
44+
) && current_page.has_css?('table#table tbody tr')
45+
end
4446
end
4547

4648
scenario 'Search query yields intended results' do

0 commit comments

Comments
 (0)