Sha256: c21c584f40d2950fd8f754a66facd8bc9f5cee7d899abb28886504f074ed0fb1
Contents?: true
Size: 1.2 KB
Versions: 3
Compression:
Stored size: 1.2 KB
Contents
require 'spec_helper' class EnclosersTest include Fluent end describe Fluent::Enclosers do let(:watir_browser) { mock_browser_for_watir } let(:watir_definition) { EnclosersTest.new(watir_browser) } context 'a definition using watir-webdriver' do it 'should handle alert message boxes' do watir_browser.should_receive(:alert).exactly(3).times.and_return(watir_browser) watir_browser.should_receive(:exists?).and_return(true) watir_browser.should_receive(:text) watir_browser.should_receive(:ok) watir_definition.will_alert do end end it 'should handle confirmation message boxes' do watir_browser.should_receive(:alert).exactly(3).times.and_return(watir_browser) watir_browser.should_receive(:exists?).and_return(true) watir_browser.should_receive(:text) watir_browser.should_receive(:ok) watir_definition.will_confirm(true) do end end it 'should handle prompt message boxes' do watir_browser.should_receive(:wd).twice.and_return(watir_browser) watir_browser.should_receive(:execute_script).twice watir_definition.will_prompt('Testing') do end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
fluent-0.4.0 | spec/enclosers_spec.rb |
fluent-0.3.0 | spec/enclosers_spec.rb |
fluent-0.2.0 | spec/enclosers_spec.rb |