Commits on Jul 1, 2012
  1. Inject size matching into base enumerable matcher

    zaphod42 committed Jul 1, 2012
    By controlling the size matching externally the base matcher can be used
    for both the exact includes matches as well as the subset includes
  2. Created includes matcher

    zaphod42 committed Jul 1, 2012
    This matcher is used to match a subset of an enumerable.
    The implementation is horrible. Need to have some more matchers and
    compose to remove duplication.
Commits on Jun 30, 2012
  1. Merge pull request #1 from coreyhaines/master

    zaphod42 committed Jun 30, 2012
    Default parameter vs explicit nil passing
  2. Allow such_that matchers to co-exist

    zaphod42 committed Jun 30, 2012
    Because the such_that matcher was adding the passed block as the
    matches? method to its own class, different such_that matchers would end
    up stomping on each other's matches? methods.
    The matches? method is now put on the singleton class so that each
    instance of a such_that matcher is independent of the others.
  3. Extracted common code from enumerable matchers

    zaphod42 committed Jun 30, 2012
    The two enumerable matchers were duplicating a bit of their behavior.
    This superclass provides a template for the enumerable matchers so that
    I don't have to duplicate all that code.
    This may be temporary, since the matchers will probably need to diverge
    as their descriptions get better and better.
  4. Created a matcher for constructing ad-hoc matchers

    zaphod42 committed Jun 30, 2012
    such_that can be used to create matchers on the fly that can still
    create understandable descriptions of what they are matching and wht the
    mismatch was.
  5. Created includes_exactly matcher

    zaphod42 committed Jun 30, 2012
    This is the equivalent of the Hamcrest contains() matcher. Changed the
    name to match ruby terminology (includes?) and clarify something that
    had always bugged me and every other user of Hamcrest that I know:
    contains makes it sounds like it will match a subset.
  6. Allow is() to take matchers

    zaphod42 committed Jun 30, 2012
    Split out EqualTo from Is so that the Is matcher can take matchers as
    arguements and coerces values into an equal_to match.
  7. Add gemspec

    zaphod42 committed Jun 30, 2012
Commits on May 12, 2012
  1. Convert to using module_function

    zaphod42 committed May 12, 2012
    This allows accessing the methods in either a short or a long (fully
    qualified) form. This also solves the problem of using anything() as
    the default for the value match in has_attribute() and causing the
    anything() method to become part of the HasAttribute module.
  2. Private doesn't do anything for mixins

    zaphod42 committed May 12, 2012
    It looks like you can't mixin methods as private in ruby. What?! So
    anything that is brought in is not able to be hidden from users.
    This will cause a problem with the default to use the anything() matcher
    in the has_attribute() matcher. For the time being the anything() method
    will have to be available from the Ramcrest::HasAttribute module.