Commits on Feb 23, 2013
  1. @myronmarston

    2.13.0 release

    myronmarston committed Feb 23, 2013
  2. @myronmarston
  3. @myronmarston

    Put enhancements first to highlight them.

    [ci skip]
    myronmarston committed Feb 23, 2013
  4. @myronmarston

    Add missing changelog entries.

    [ci skip]
    myronmarston committed Feb 23, 2013
Commits on Feb 18, 2013
  1. @myronmarston
Commits on Feb 17, 2013
  1. @myronmarston

    rbx-18 is failing with strange errors on travis.

    Missing or uninitialized constant: RbConfig (NameError)
    
    I don't have the energy to fight with it now :(.
    myronmarston committed Feb 16, 2013
Commits on Feb 16, 2013
  1. @myronmarston

    Fix `include` matcher so that its matcher-detection logic is more rob…

    …ust.
    
    - Don't treat an object that responds to everything (such as a null object
      double) as a matcher.
    - Don't treat an object that responds to #matches? but not other parts of
      the matcher protocol as a matcher. `#matches?` is a common enough method
      name that it's easy to imagine domain objects that define this method
      but are not intended to be used as rspec matchers.
    - Ensure both old and new style matchers work.  It used to be `failure_message`
      but changed at some point to `failure_message_for_should`.
    
    Fixes #211.
    myronmarston committed Feb 16, 2013
Commits on Feb 13, 2013
  1. @myronmarston

    Merge pull request #209 from pjambet/use_new_codeclimate_shield

    Use new Codeclimate badge, made by @olivierlacan
    myronmarston committed Feb 13, 2013
  2. @pjambet
Commits on Feb 10, 2013
  1. @myronmarston
  2. @myronmarston
  3. @myronmarston

    Shorten verbose matcher name.

    string_containing_string => a_string_containing
    myronmarston committed Feb 9, 2013
  4. @myronmarston

    When composing matchers with `include` it should not be diffable.

    Otherwise, we get ridiculous output like:
    
         Failure/Error: expect(['foo', 'bar', 'baz']).to include(string_containing_string("abc"))
           expected ["foo", "bar", "baz"] to include a string containing 'abc'
           Diff:
           @@ -1,30 +1,2 @@
           -[#<RSpec::Matchers::DSL::Matcher:0x007fb244f536f8
           -  @actual="baz",
           -  @declarations=
           -   #<Proc:0x007fb244c1a5e0@/Users/myron/code/rspec-dev/repos/rspec-expectations/spec/rspec/matchers/include_spec.rb:390>,
           -  @diffable=false,
           -  @expected=["abc"],
           -  @expected_exception=nil,
           -  @match_block=
           -   #<Proc:0x007fb244f52b18@/Users/myron/code/rspec-dev/repos/rspec-expectations/spec/rspec/matchers/include_spec.rb:391>,
           -  @match_for_should_not_block=nil,
           -  @matcher_execution_context=
           -   #<RSpec::Core::ExampleGroup::Nested_89::Nested_1:0x007fb244f53dd8
           -    @example=
           -     #<RSpec::Core::Example:0x007fb244c378e8
           -      @around_each_hooks=nil,
           -      @example_block=nil,
           -      @example_group_class=nil,
           -      @example_group_instance=nil,
           -      @exception=nil,
           -      @metadata=nil,
           -      @options=nil,
           -      @pending_declared_in_example=nil>,
           -    @matcher_execution_context=
           -     #<RSpec::Core::ExampleGroup::Nested_89::Nested_1:0x007fb244f53dd8 ...>>,
           -  @messages=
           -   {:description=>
           -     #<Proc:0x007fb244f52af0@/Users/myron/code/rspec-dev/repos/rspec-expectations/spec/rspec/matchers/include_spec.rb:395>},
           -  @name=:string_containing_string,
           -  @rescued_exception=nil>]
           +["foo", "bar", "baz"]
    myronmarston committed Feb 9, 2013
  5. @myronmarston

    Cleanup whitespace.

    myronmarston committed Feb 5, 2013
  6. @myronmarston
  7. @lukeredpath @myronmarston
  8. @lukeredpath @myronmarston

    Started to add some integration specs to show the interaction between…

    … include()
    
    matcher support and the built-in matchers.
    lukeredpath committed with myronmarston Jul 26, 2011
  9. @lukeredpath @myronmarston
  10. @lukeredpath @myronmarston
  11. @lukeredpath @myronmarston

    Should be able to do fuzzy matching against arrays using include?(som…

    …e_matcher) or include?(array_of_matchers).
    
    I've deliberately only implemented fuzzy matching support for arrays right now, it might make sense
    to extend support to hashes though.
    lukeredpath committed with myronmarston Jul 25, 2011
  12. @lukeredpath @myronmarston
  13. @myronmarston
  14. @myronmarston

    Try to fix the build by no longer requiring test/unit.

    Our travis builds have started failing with:
    
    /home/travis/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/test/unit.rb:49:in `process_args': invalid option: --format (OptionParser::InvalidOption)
    	from /home/travis/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/minitest/unit.rb:891:in `_run'
    	from /home/travis/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/minitest/unit.rb:884:in `run'
    	from /home/travis/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/test/unit.rb:21:in `run'
    	from /home/travis/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/test/unit.rb:326:in `block (2 levels) in autorun'
    	from /home/travis/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/test/unit.rb:27:in `run_once'
    	from /home/travis/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/test/unit.rb:325:in `block in autorun'
    
    ...so we no longer want to require `test/unit` in spec_helper.rb.  However, there are 3 examples that are specifically testing integration with test/unit (for folks who use rspec-expectations w/ it). My attempted solution is to sandbox the require of test/unit in a subprocess that exits with `exit!` to skip test/unit's `at_exit` hook.
    myronmarston committed Feb 9, 2013
  15. @myronmarston
Commits on Feb 9, 2013
  1. @alindeman

    Corrects syntax of gemspec

    alindeman committed Feb 9, 2013
  2. @alindeman

    Merge pull request #204 from halostatue/patch-1

    Limit diff-lcs to 1.x series only
    alindeman committed Feb 9, 2013
  3. @halostatue

    Limit diff-lcs to 1.x series only

    I have some experimental code that I am working with that may change the
    Diff::LCS interface in version 2.0 (whenever that drops). I would like
    to encourage the adoption of the (currently bug-free) 1.2 release as
    much as possible, but I don't want to cause other problems if the future
    release changes.
    halostatue committed Feb 9, 2013
Commits on Feb 7, 2013
  1. @myronmarston

    Fix caching bugs in DSL matchers.

    Previously, `@messages` was not cleared when new instances
    were created, so the `description`, `failure_message_for_should`
    and `failure_message_for_should_not` blocks would take on the
    value set by the most recently built instance.
    
    In a case like:
    
    RSpec::Matchers.define(:be_like_a) do |expected|
      description { "be like a #{expected}" }
    end
    
    be_like_a_moose = be_like_a("moose")
    be_like_a_horse = be_like_a("horse")
    
    ...each matcher instance eval'd the `define` block once.
    Since the object that holds a reference to the description
    block (the `@messages` instance variable) was not cleared
    between the two examples, the description block for both
    instances would have `expected` bound to "horse" (since
    it was instantiated last, and its define block eval'd last).
    
    This caused the description and failure messages to return
    the wrong values in situations like these.
    myronmarston committed Feb 5, 2013
Commits on Feb 6, 2013
  1. @myronmarston

    Merge pull request #203 from rspec/remove_confusing_message

    Remove confusing empty diff message.
    myronmarston committed Feb 6, 2013
Commits on Feb 4, 2013
  1. @myronmarston

    Remove confusing empty diff message.

    The existing message made assumptions (e.g. that `==` was used for comparison)
    there were not always true, causing confusion.
    
    Fixes #143.
    myronmarston committed Feb 3, 2013
Commits on Feb 3, 2013
  1. @myronmarston

    Fix fail_with so it handles strings in any encoding.

    Previously we would get an Encoding::CompatibilityError if
    an encoding was used that's not ASCII compatible.
    
    Fixes #201.
    myronmarston committed Feb 1, 2013
Commits on Jan 22, 2013
  1. @myronmarston

    Update Changelog.

    [ci skip]
    myronmarston committed Jan 22, 2013
  2. @myronmarston

    Merge pull request #200 from enthuseinc/feature/support_diff-lcs_1.2.x

    Add support for diff-lcs 1.2.x while maintaining backwards compatibility with 1.1.3
    myronmarston committed Jan 22, 2013
  3. @petergoldstein

    Add support for diff-lcs 1.2.x while maintaining backwards compatibil…

    …ity with diff-lcs 1.1.3. Updated gemspec to support either as a runtime dependency.
    petergoldstein committed Jan 22, 2013
Commits on Jan 15, 2013
  1. @myronmarston