spec/integration/napybara_spec.rb in napybara-0.1.0 vs spec/integration/napybara_spec.rb in napybara-0.2.0
- old
+ new
@@ -9,16 +9,18 @@
Capybara::Session.new(:poltergeist, DummyApp)
end
let(:test_page) do
Napybara::DSL.build(session) do
- def element.visit!
- visit '/test.html'
+ extend_element do
+ def visit!
+ visit '/test.html'
+ end
end
- form 'form' do
- notice_updater 'button.update'
- notice '.notice'
+ find :form, 'form' do
+ find :notice_updater, 'button.update'
+ find :notice, '.notice'
end
end
end
Steps do