ruby - ChildProcess::LaunchError for browsermob proxy server start -


i'm trying use browsermob proxy in selenium tests. hence wrote following code:

require 'selenium-webdriver' require 'browsermob/proxy'  server = browsermob::proxy::server.new 'e:\browsermob\browsermob-proxy-2.0-beta-8' server.start 

but when run above script, results childprocess::launcherror :

childprocess::launcherror: unknown error (windows says "the operation completed successfully.", did not.)     c:/ruby193/lib/ruby/gems/1.9.1/gems/childprocess-0.3.9/lib/childprocess/windows/process_builder.rb:87:in `create_process'     c:/ruby193/lib/ruby/gems/1.9.1/gems/childprocess-0.3.9/lib/childprocess/windows/process_builder.rb:34:in `start'     c:/ruby193/lib/ruby/gems/1.9.1/gems/childprocess-0.3.9/lib/childprocess/windows/process.rb:63:in `launch_process'     c:/ruby193/lib/ruby/gems/1.9.1/gems/childprocess-0.3.9/lib/childprocess/abstract_process.rb:72:in `start'     c:/ruby193/lib/ruby/gems/1.9.1/gems/browsermob-proxy-0.1.3/lib/browsermob/proxy/server.rb:27:in `start'     (irb):9     c:/ruby193/bin/irb:12:in `<main>' 

please me solve issue.

i faced same issue , hard figure out documentation here understand path browsermob-proxy server should include executable.

in case code should next:

require 'selenium-webdriver' require 'browsermob/proxy'

server = browsermob::proxy::server.new "e:\browsermob\browsermob-proxy-2.0-beta-8\browsermob-proxy" server.start

hope helps


Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -

php - Accessing static methods using newly created $obj or using class Name -