# File lib/selenium/client/javascript_expression_builder.rb, line 64 64: def find_text_in_document(pattern, options) 65: js_regexp = case pattern 66: when Regexp 67: pattern.inspect 68: else 69: /#{pattern}/.inspect 70: end 71: append "var text_match;\ntext_match = (null != selenium.browserbot.getCurrentWindow().document.body.innerHTML.match(\#{js_regexp}));\n" 72: 73: end