Class: WatirSplash::Browser
- Inherits:
-
Object
- Object
- WatirSplash::Browser
- Defined in:
- lib/watirsplash/browser.rb,
lib/watirsplash/frameworks/watir-webdriver/ie.rb,
lib/watirsplash/frameworks/watir-webdriver/chrome.rb,
lib/watirsplash/frameworks/watir-webdriver/firefox.rb
Constant Summary collapse
- JAVASCRIPT_ERRORS_CHECKER =
raises an error if any JavaScript errors were found
lambda do |browser| = browser.execute_script %q[ var msg = window.__browserErrorMessage; window.__browserErrorMessage = undefined; return msg; ] raise JavaScriptError, "JavaScript error: #{}" if browser.execute_script %q[ if (!window.onErrorFn) { window.onErrorFn = function(errorMsg, url, lineNumber) { window.__browserErrorMessage = errorMsg + " @ " + url + ":" + lineNumber; if (window.__onErrorFn) window.__onErrorFn(errorMsg, url, lineNumber); return false; }; window.__onErrorFn = window.onerror; window.onerror = window.onErrorFn; }] end
Class Attribute Summary collapse
-
.current ⇒ Object
Returns the value of attribute current.
Class Method Summary collapse
- .exist? ⇒ Boolean (also: exists?)
- .new ⇒ Object
Class Attribute Details
.current ⇒ Object
Returns the value of attribute current.
33 34 35 |
# File 'lib/watirsplash/browser.rb', line 33 def current @current end |