schwern/test-more — Issue #185: Remove Event's as_hash() methods
Author: schwern
Created: 2011-11-08 22:07:17+00:00
State: open
Labels: DO IT, Easy, Events, Gardening, Test-Builder2

Test::Builder2::Event now supplies (or will once #182 is done) a default `as_hash` method. Events no longer have to define their own and probably should not. Instead they should override `keys_for_as_hash` to add any extra non-attributes.

Go through the existing events...

* remove their `as_hash` overrides
* adapt the tests
* make sure all the event's relevant information is supplied by `as_hash`

Removing `as_hash` will pick up more items than the hard coded one did. At minimum it will pick up file and line inherited from Event, but it might pick up more that were forgotten in the override.