But about 1/2 of the listed "libraries used" are no longer functioning links.
I also looked at watir http://wtr.rubyforge.org/
which looked nice, but unfortunately requires Internet Explorer via a
COM interface, and I am looking to run this test on a linux server via
cron.
Are there some other useful web testing libraries people could point me towards?
Take a look at Michael Neumann's WWW::Mechanize. He has made it very
easy to code up an app to fetch a page, find pertinent content, follow
links, and so on.
It uses client-side Javascript to control the browser. There is a Ruby
interface, or you can specify the tests as a bunch of HTML tables that have
actions and assertions. (There are also interfaces for Java, .NET and
Python.)
I haven't used the Ruby interface, but started using the table-based one
today.
···
In article <5c2874720502071041543561d3@mail.gmail.com>, Jason Sweat wrote:
Does anyone have suggestions for projects/libraries to web test code
(HTMLUnit like)?
But about 1/2 of the listed "libraries used" are no longer functioning links.
I also looked at watir http://wtr.rubyforge.org/
which looked nice, but unfortunately requires Internet Explorer via a
COM interface, and I am looking to run this test on a linux server via
cron.
Are there some other useful web testing libraries people could point me towards?
I also looked at watir http://wtr.rubyforge.org/
which looked nice, but unfortunately requires Internet Explorer via a
COM interface, and I am looking to run this test on a linux server via
cron.
On Tue, 8 Feb 2005 04:20:35 +0900, James G. Britt <ruby.talk.list@gmail.com> wrote:
On Tue, 8 Feb 2005 03:41:21 +0900, Jason Sweat <jason.sweat@gmail.com> wrote:
> Does anyone have suggestions for projects/libraries to web test code
> (HTMLUnit like)?
Take a look at Michael Neumann's WWW::Mechanize. He has made it very
easy to code up an app to fetch a page, find pertinent content, follow
links, and so on.
$ ruby test.rb
I, [2005-02-08T09:30:10.092550 #1947] INFO -- : GET: https://www.alcoadirect.com/
warning: peer certificate won't be verified in this SSL session
D, [2005-02-08T09:30:14.305853 #1947] DEBUG -- : request-header: accept => */*
D, [2005-02-08T09:30:14.393482 #1947] DEBUG -- : header: last-modified
: Tue, 08 Feb 2005 00:02:27 GMT
D, [2005-02-08T09:30:14.393568 #1947] DEBUG -- : header: content-type
: text/html
D, [2005-02-08T09:30:14.393607 #1947] DEBUG -- : header: date : Tue,
08 Feb 2005 15:30:43 GMT
D, [2005-02-08T09:30:14.393646 #1947] DEBUG -- : header: server : JRun
Web Server/3.0
D, [2005-02-08T09:30:14.393684 #1947] DEBUG -- : header:
transfer-encoding : chunked
I, [2005-02-08T09:30:14.554417 #1947] INFO -- : status: 200
/usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize.rb:115:in
`parse': undefined method `downcase' for nil:NilClass (NoMethodError)
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize.rb:112:in
`call'
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize/parsing.rb:14:in
`each_recursive'
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize/parsing.rb:13:in
`each'
from /usr/lib/ruby/1.9/rexml/element.rb:916:in `each'
from /usr/lib/ruby/1.9/rexml/xpath.rb:49:in `each'
from /usr/lib/ruby/1.9/rexml/element.rb:916:in `each'
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize/parsing.rb:13:in
`each_recursive'
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize/parsing.rb:15:in
`each_recursive'
... 136 levels...
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize/parsing.rb:13:in
`each_recursive'
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize.rb:212:in
`parse_html'
from /usr/lib/ruby/gems/1.9/gems/mechanize-0.1.0/lib/mechanize.rb:164:in
`forms'
from test.rb:6
Is the HTML parser perhaps dependant on well formed HTML? Is there a
more appropriate forum for me to raise this issue? Thanks.
Regards,
Jason
···
On Tue, 8 Feb 2005 04:20:35 +0900, James G. Britt <ruby.talk.list@gmail.com> wrote:
On Tue, 8 Feb 2005 03:41:21 +0900, Jason Sweat <jason.sweat@gmail.com> wrote:
> Does anyone have suggestions for projects/libraries to web test code
> (HTMLUnit like)?
Take a look at Michael Neumann's WWW::Mechanize. He has made it very
easy to code up an app to fetch a page, find pertinent content, follow
links, and so on.