File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22 let! ( :next_workshop ) { Fabricate ( :workshop ) }
33 let! ( :events ) { Fabricate . times ( 3 , :event ) }
44
5- before ( :each ) do
5+ before do
66 visit root_path
77 end
88
1111 end
1212
1313 scenario 'i can view the next workshop' do
14- expect ( page ) . to have_content "Workshop at #{ next_workshop . host . name } "
14+ travel_to ( Time . current ) do
15+ expect ( page ) . to have_content "Workshop at #{ next_workshop . host . name } "
16+ end
1517 end
1618
1719 scenario 'i can view the next 5 upcoming events' do
18- events . take ( 5 ) . each { |event | expect ( page ) . to have_content "#{ event . name } at #{ event . venue . name } " }
20+ travel_to ( Time . current ) do
21+ events . take ( 5 ) . each { |event | expect ( page ) . to have_content "#{ event . name } at #{ event . venue . name } " }
22+ end
1923 end
2024
2125 scenario 'i can access the code of conduct' do
3741 end
3842
3943 inactive_chapters . each do |chapter |
40- expect ( page ) . to_not have_content ( chapter . name )
44+ expect ( page ) . not_to have_content ( chapter . name )
4145 end
4246 end
4347
You can’t perform that action at this time.
0 commit comments