TO DO:
. Improve test coverage of methods
. Add test for ->value with 3-args (setting)
. Add test for ->highlight_node()
. Add test for ->set_visible()
. Add test for ->clickables()
. Add test for getting/setting ->autodie()
. Add test for getting/setting ->events()
. Add 2-arg test for ->synchronize()
. Make ->set_visible actually use ->field()
so it can also set select fields?!
. Make ->set_visible also support select+option inputs
0.59 20120211
+ Report Javascript errors from the perspective of the caller
instead of a location in WWW::Mechanize::Firefox
! ->wait_until_invisible() requeries selectors now instead
of only querying them once.
+ Add target size options when converting HTML to PNG
+ WWW::Mechanize::Firefox is currently tested against the following versions
- 3.0.19
- 3.5.19
- 3.6.19
- 5.0.1
- 6.0.1
- 7.0.1
- 8.0
- 9.0
- 10.0
0.58 20111128
! Fix cookie handling which was weirdly broken yet the tests passed.
Session cookies now get returned
Thanks to blakew for pointing that out
0.57 20111102
. Make relative queries work for ->selector()
with "node => $foo"
Reported by Rolf Langsdorf
0.56 20111031
. Make "frames => 0" work in constructor (+test)
0.55 20110728
. Re-release of 0.54, this time including t/helper.pm for the tests
0.54 20110726
+ Bugfix: Tabs on FF4+ now only get closed once, preventing FF lockups
+ Bugfix: ->set_visible now also finds input fields without "type" attribute
. ->set_visible() now also has tests
+ WWW::Mechanize::Firefox is currently tested against the following versions
- 3.0.19
- 3.5.19
- 3.6.19
- 4.0.1
- 5.0.1
- 6.0 Beta
. The tests can now run against other Firefox installations under
firefox-versions/(v.v.v)/FirefoxPortable.exe
. The search glob for Firefox versions to run the tests against can
be set via $ENV{TEST_WWW_MECHANIZE_FIREFOX_VERSIONS}
The default is firefox-versions/*/FirefoxPortable*
0.53 20110701
! Renamed ff-scrape.pl to scrape-ff.pl
. scrape-ff.pl now supports attribute selection with CSS selectors
+ Bugfix: ->form_with_fields() ignored textarea and select fields
0.52 20110509
. Remove traces of Firefox 4 being unsupported
. Added license to API35.pm and API40.pm
. Upgrade local test server to more current incarnation
. Eliminate almost all tests that need an outside network connection
. Document Firefox 4 bug
L<https://bugzilla.mozilla.org/show_bug.cgi?id=649924>
0.51 20110502
. Add pageshow event to the default set of monitored events.
Pageshow fires when a page is loaded from the cache.
+ Firefox 4 is now supported in addition to Firefox 3.5+
Firefox 4 support is not really tested outside of the module self-tests.
+ ->get() can now optionally not synchronize, like ->click(), suggested
and coded by Dave Hansen
0.50 20110411
. implement ->text() and ->content( format => 'text' )
+ autodie is now on by default
. The screenshot example can now also use the current tab
0.49 20110403
. Fix for RT #67195
->find_link_dom( text => 'foo' ) was (much) slower than it needed to be
Fix and report by Dave Hansen
0.48 20110317
. Implemented ->click_button() function plus tests
Tests courtesy of WWW::Mechanize 1.66
. Allow "OR" for node type via using local-name(.) (the element name)
. Use the ugly cross-version hack of
translate(local-name(.), 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')
to accomodate for Firefox 3.0 having UPPERCASE HTML ELEMENT NAMES
and Firefox 3.6+ having lowercase html element names. Once we move to 4.0
support only, this can be reverted to
local-name(.)
0.47 20110311
. Use URI::data instead of hand-rolling URI construction
. Add missing prerequisites from LWP split-up
+ HTTP::Cookies::MozRepl can now ->set_cookie to create a cookie in Firefox
* Bugfix: ->save_url() did not send cookies, reported and diagnosed by tcordes
. Add test for ->save_url() and ->get() to check that they send cookies
0.46 20110222
. Add another, more local test for large pages
. Add hint about bufsize to Troubleshooting.pod
. Add test that bufsize actually takes effect
! Somewhat experimental squashing of multiple Xpath queries into one
query - if this breaks your code, please supply test cases!
0.45 20110208
. eval_in_page raises errors from perspective of the caller
instead of raising errors in Firefox.pm
. Added ->by_id() method and { id => $id } option for
conveniently finding elements with names that ->selector
interprets as CSS selectors.
. Improved tests checking fields with fancy:names
or fancy:ids
0.44 20100130
. Allow ->click() on <input type="image"> inputs
(provided by ysth, thanks)
. Bump MozRepl::RemoteObject to 0.21 for better cleanup logic
0.43 20110109
! Fix MozRepl::RemoteObject prerequisite version number
! Change event filtering logic for load progress listener to
just pre-filter, and keep the main logic in Perl. This
should fix intermittent crashes.
. Add 'no_cache' option to ->get()
0.42 20110106
. Improved subroutine coverage to 95% on WWW::Mechanize::Firefox
. Add test for ->forms in scalar context
. Add test for ->forms in list context
. Add test for ->reload()
. Add test for ->back()
. Add test for ->forward()
. Add test for ->is_html()
. ->back() / ->forward() now can optionally (not) synchronize
for loading local files
. Move page load progress listener into JS to reduce latency
. Added ->on_event() accessor for convenient JS page load event debugging
0.41 20101211
. Remove failing test that didn't respect localized theme names
. Fix (i)frame tests that didn't produce results due to embedding sites
that didn't load.
. Proxies in Firefox should impede test results less
. FRAME tags are handled somewhat differently between Firefox and Mechanize:
Firefox is less lenient than WWW::Mechanize
. Use the new ->constant() mechanism of MozRepl::RemoteObject to improve
latency
. ->set_fields() now actually works and has a test
. Started monitoring code coverage through Devel::Cover
. Reinstate `use_queue` that was broken in 0.39
. ->synchronize() now captures events from the tab and the browser
0.40 20101122
+ HTTP::Cookies::MozRepl now fetches cookies more quickly
+ Other functions also use bulk fetching for quicker
information retrieval
. The tests are now more resilient for proxies that return other
"no DNS" errors than 500.
0.39 20101120
. Add Firefox::Application to contain UI manipulation things.
The ->{repl} element is now not a hash element of WWW::Mechanize::Firefox
anymore, but you shouldn't access the guts of an object anyway.
Use ->repl instead.
! ->addTab , ->createTab, ->activateTab and ->selectedTab have been moved
to Firefox::Application.
If you used these functions before, change:
$mech->addTab( ... )
to
$mech->application->addTab( ... )
! ->set_tab_content has been moved to Firefox::Application
! WWW::Mechanize::Firefox (by virtue of Firefox::Application) now uses
the command queueing feature of MozRepl::RemoteObject. The change
should be invisible in theory, but as Javascript objects now experience
a short delay in when they get released, it might change the behaviour
of Firefox. If you experience different behaviour, please test with
use_queue => 1
and
use_queue => 0
whether the difference actually stems from the queuing behaviour.
0.38 20101119
. Fix test for checking whether JS is enabled and whether it can be
disabled to also work when the NoScript add-on is not installed.
! Fix test and code for ->response (and ->get()) when a HTTP proxy
is set. This means that if you have a proxy, some of the response
codes may differ from what you saw before. Some responses are now
404 or 500 responses where they returned undef before.
! The response code should now more closely correspond to the first
response actually fetched.
. Always store (a reference to) the Javascript response even if we
don't fetch it immediately.
. The examples now have a common hashbang line
. The examples don't use a private library directory anymore
0.37 20101115
. Switch out the code in WWW::Mechanize::Firefox::DSL
in favour of Object::Import, which is the same codebase
but intended for a wider audience than just W:M:F.
. ->current_form now gets reset on ->get and ->submit
. The C<any> option to ->xpath() (and ->selector, ->is_visible,...)
allows to search for multiple nodes that may or may not exist
0.36 20101017
. Fix the mro.pm 5.10+ prerequisite by using the additional prerequisite
MRO::Compat, which provides a transparent switch between mro.pm and its
own implementation for versions <5.9.x.
. Make `use WWW::Mechanize::Firefox::DSL '$mech'` work silently
. JS Errors when using ::DSL now get raised in the user code and not
in ::Firefox or ::DSL
0.35 20101014
. Improve the error message of ->value() when no element is found
. Implement ->tick() and ->untick()
0.34 20101013
. Make ->follow_link() also respect C<synchronize> by making ->follow_link()
mostly synonymous with ->click()
. Document the C<dom> option to ->click() (noted by M. Schwern)
. ->click(undef) now fails
. Optimized ->get_set_field() to only return a value if it's needed. This
should speed up setting values in selectboxes.
. Added section in Troubleshooting.pod on what C<synchronize> can be
used for.
0.33 20100819
. Add ->activateTab() for setting the currently displayed tab
. Now needs MozRepl::RemoteObject 0.13 as a prerequisite
. Add activate => 1 option to constructor
. Remove ->content_utf8 , as ->content() already always returns utf8
+ Bring ->field() and ->value() in line with the HTML::Form API
(and thus the WWW::Mechanize API). Now, very simple CSS
selectors like #id and .class get accepted in addition
to 'name' and '^name'.
+ ->value() now also returns the values for select+option elements
0.32 20100810
. Add WWW::Mechanize::Firefox::FAQ as a list of frequently asked
questions. As people now actually ask questions, this file
has a reason to exist.
. Add WWW::Mechanize::Firefox::Troubleshooting as a document
for things that still need to be implemented. Also list
workarounds.
. Add example for how to change Firefox settings.
. Change code for closing a tab so it works dynamically
. Add method ->closeTab for closing arbitrary tabs and a test for it
. Add experimental ->content_utf8 method that always tries to decode
the content.
! All HTTP::Response objects now use ->content_utf8() instead of
expecting the content to be in utf8. This may break your
encoding-sensitive code, so please send me test cases where it breaks
for you.
0.31 20100713
. ->get now supports the :local_file shortcut for local saving
. WWW::Mechanize::Firefox::Cookbook contains snippets
. Documentation is more unified, short examples of function usage
0.30 20100711
. Add ->is_visible method to check for node visibility
. Add ->wait_until_invisible method to wait until a node disappears
. Add tests for the above
. Added tail example program for tailing the Javascript console
. Added example program to send messages from the console to the Javascript
console (intended to delineate the start/stop of test runs)
0.29 20100704
. Really fix bcat.pl and failing tests
. Use Firefox XPath library for ->find_link( text_contains => ... )
. Can't use Firefox XPath library for ->find_link( text_regex => ... )
as Firefox does not seem to define fn:matches()
. ->find_link() now really searches only the current frame, as Mechanize does
0.28 20100702
. Fix bcat.pl and failing tests
. Add examples on how to access (and follow) the Error Console
0.27 20100701
. Add the examples to WWW::Mechanize::Firefox::Examples
. Add test for (dis)allowing META redirects
. Add author test to ensure Changes well-formedness
. Fix 'one' option to ->xpath() to correctly fail when no element is found
. Fix behaviour of ->click() to correctly fail if no element is found
when given as a name
0.26 20100630
. Add bcat.pl example to display text from the console in the browser
. Make input fields work across frames
. Add test for fields across frames
. Make ->field() and ->value() respect the current form if any
0.25 20100629
. ->submit_form now can submit the current form without any fields
specified. This was a fatal error before.
. The Javascript code for closing a tab is now much shorter and likely
also more reliable as it does not rely on the most recent window
opened anymore.
. ->update_html() does not return anything anymore, just like
WWW::Mechanize does.
. C<repl> constructor now also accepts host:port
. Add `bcat.pl` example script to cat HTML to the browser.
0.24 20100624
! ->find_link_dom now uses ->xpath and searches through frames
! Actually conform to WWW::Mechanize API by requiring a hashref
in ->submit_form( with_fields => {} ). This might break your
code, but it's a small change and makes the code fit the documentation.
0.23 20100624
. Add "maybe" option to ->xpath (and ->selector)
. Add "all" option to ->xpath (and ->selector)
. Add a sanity check that prevents calling ->xpath in scalar
context if no item-count option is specified.
. Unified code paths for frame expansion and document query
0.22 20100623
. Performance optimization:
->click() does not need a response
. ->click() now uses ->xpath() to find elements
. Add link to WWW::Mechanize::Firefox::Examples
. Don't force C<synchronize> in ->click()
. ->xpath also takes an arrayref of queries
. ->selector also takes an arrayref of queries
. Added INSTALL file
0.21 20100618
! value() method now returns the field value
! Frames are now searched by default for matching elements
Use
frames => 0
to prevent searching through frames or
frames => ['content_frame']
to whitelist frames to be searched
0.20 20100610
. Fix links in example documentation
. Add tests for weirdo names containing square brackets
. Fix finding fields that have square brackets in their attributes
0.19 20100603
. Added example programs
. Generate example documentation by script from John McNamara
0.18 20100518
. ->submit() returns a true value now
. added another test
. Add test and fix bug in ->form_with_fields, which never worked properly
. Add test and fix bug in ->form_name, which never worked at all
0.17 20100426
. Don't only request nsiHttpChannel, also use it instead of $request
. Fix warnings in test suite
. Add ->eval() as synonym for ->eval_in_page()
. Fix distribution MANIFEST
0.16 20100425
. Added ->submit
. Added ->submit_form with_fields => [...]
. Bugfix: Explicitly ask for the nsiHTTPChannel when trying to
create a response
0.15 20091216
. Better Makefile.PL and Prereq patch by Alexandr Ciornii (chorny)
. Removed some dead code
. Fixed some incompatible Javascript
0.14 20091215
. Added documentation about bufsize parameter
. Option to recursively search frames
0.13 20091213
. Added way to use the "current" tab instead of a new/known tab
. Fixed a bug regarding reusing tabs
. Added eg/ directory with examples
. Added way to specify maximum buffer size at startup
in response to http://perlmonks.org/?node_id=811436
0.12 20091130
! Renamed to ::Firefox
This affects all your scripts, unfortunately.
. Added ->save_url for downloading content to disk
. Added ->save_document for downloading the current document to disk
. Make ->synchronize and ->click not automatically fetch the response
. Guard against empty/undefined schemes when constructing the JS response
. Add and document a method to launch Firefox if it's not already running.
0.11 20091126
. Implement real HTTP response codes instead of the faked
response codes.
* Fix a memory leak/cycle that prevented tabs from closing
. Now needs MozRepl::RemoteObject 0.10 for the API to deregister
callbacks.
0.10 20091121
. implemented ->form_name, ->form_id, ->form_number
. unified API between ->find_link, ->selector, ->xpath
. Needs MozRepl::RemoteObject 0.09 to ensure that
multiple $mech instances work
0.09 20091111
. Allow ->eval_in_page() to specify an overriding
environment, for example to override alert()
0.08 20091109
. Make tests warn if I suspect that Javascript is
blocked by Noscript. This makes some tests fail.
. Require latest MozRepl::RemoteObject for sane encoding handling.
0.07 20091106
. added ->eval_in_page() to evaluate Javascript in
the context of the page
. added better frame / iframe handling.
o Frame/iframes don't play well with data: URLs.
0.06 20091102
. added 'autoclose' parameter to specify whether the
tab that mechanize creates gets automatically closed upon
object release
. added ->content_as_png() to save the current page
as PNG
. Added 'single' option to ->selector() and ->xpath()
. Added capture of arbitrary rectangles to ->content_as_png()
. added ->find_link APIs
. added ->find_link tests from WWW::Mechanize
. added sending of focus/change/blur events and API
0.05 20091030
. Added HTTP::Cookies::MozRepl to allow for live cookie querying
. Added ->cookies method for cookie access
0.04 20091029
. Added ->set_visible
. Added ->value (partly buggy with respect to event triggering)
. added log passthrough parameter
0.03 20091028
. Added missing MIME::Base64 prerequisite
. Now has WWW::Mechanize as a prerequisite
. Also requires MozRepl::RemoteObject 0.2 due to the changed call
interface and introduction of ->declare for caching.
0.02 20091027
. rearranged documentation
. made tests skip if we can't connect to MozRepl
0.01 20091026
. Released unto a propably suspecting audience