Hamcrest-PHP 1.1.0 is out

4 views
Skip to first unread message

David Harkness

unread,
Feb 3, 2012, 12:00:19 AM2/3/12
to hamcre...@googlegroups.com
Greetings fellow PHPers,

I had some time to work on Hamcrest today while our Comcast cable was out of commission. :) I added a few features and did some code cleanup and released version 1.1 via PEAR. Here is the list of changes in today's release:

Issues Fixed: 121, 138, 147

* Added non-empty matchers to complement the emptiness-matching forms.

- nonEmptyString()
- nonEmptyArray()
- nonEmptyTraversable()

* Added ability to pass variable arguments to several array-based matcher
factory methods so they work like allOf() et al.

- anArray()
- arrayContainingInAnyOrder(), containsInAnyOrder()
- arrayContaining(), contains()
- stringContainsInOrder()

* Matchers that accept an array of matchers now also accept variable arguments.
Any non-matcher arguments are wrapped by IsEqual.

* Added noneOf() as a shortcut for not(anyOf()). Hmm, the second and third features are the same. One was supposed to relate to the code cleaning by moving the "turn a non-matcher into an IsEqual matcher" code into Hamcrest_Util. I guess that's what happens when you're deprived of the internet for 5 hours! :p Enjoy, David
Reply all
Reply to author
Forward
0 new messages