私は、IE クラスを使用してサイトをナビゲートしたり、クエリを発行したりする、Watir を使用したサンプル テストを作成しています。これは完全に機能します。
着陸した最後のページでPageContainerのメソッドを使用して続行したいと思います。たとえば、そのページでその HTML メソッドを使用します。
Ruby は初めてで、Watir の学習を始めたばかりです。
OpenQAでこの質問をしてみたのですが、なぜかWatirのセクションは一般会員限定になっています。
私の質問を見てくれてありがとう。
編集:これは簡単な例です
require "rubygems"
require "watir"
test_site = "http://wiki.openqa.org/"
browser = Watir::IE.new
browser.goto(test_site)
# now if I want to get the HTML source of this page, I can't use the IE class
# because it doesn't have a method which supports that
# the PageContainer class, does have a method that supports that
# I'll continue what I want to do in pseudo code
Store HTML source in text file
# I know how to write to a file, so that's not a problem;
# retrieving the HTML is the problem.
# more specifically, using another Watir class is the problem.
Close browser
# end