Sha256: 8db4ec26668f59e9d9a1f279b7caa670ad52624aa856c590d94135baff107852
Contents?: true
Size: 746 Bytes
Versions: 1
Compression:
Stored size: 746 Bytes
Contents
require 'spec_helper' describe "Proxy + WebDriverListener" do let(:wait) { Selenium::WebDriver::Wait.new } let(:listener) { BrowserMob::Proxy::WebDriverListener.new(proxy) } let(:driver) { Selenium::WebDriver.for :firefox, :profile => profile, :listener => listener } let(:proxy) { new_proxy } let(:profile) { pr = Selenium::WebDriver::Firefox::Profile.new pr.proxy = proxy.selenium_proxy pr } after { proxy.close } it "should record events" do driver.get url_for("1.html") driver.find_element(:link_text => "2").click driver.quit hars = listener.hars hars.size.should == 1 hars.first.pages.size.should == 2 hars.each_with_index { |e,i| e.save_to("/tmp/#{i}.har") } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
browsermob-proxy-0.0.3 | spec/e2e/listener_spec.rb |