Clone this wiki locally
Assuming that you have installed Vapir via Rubygems, you will need rubygems to be required. How to do that is discussed in The RubyGems manual , see that for details.
Then you need to require Vapir. If you already have a script or scripts written for Watir, see Coming from Watir. If you’re writing from scratch, though, carry on.
You should be able to just
And then Autoload will take care of requiring the browser-specific library when you refer to
To instantiate a browser, use one of:
browser = Vapir::IE.new
browser = Vapir::Firefox.new
browser = Vapir::Browser.new
You can also use
.attach methods which you are probably familiar with from Watir.
Requiring browser-specific libraries directly
If there’s any problem with
require 'vapir' not loading the browser-specific libraries, you can load them directly using: