Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: issue-230-for-…
Commits on Mar 17, 2013
  1. @myronmarston

    Clarify relationship between different method stub actions.

    myronmarston authored
    In 2.13.0 only `and_yield` and `and_return` could be combined, since
    that was the only combination case that was specified by an example.
    This was a regression, as reported by a user in #230.
    
    I tried here to fully specify all of the various combinations of stub 
    actions. Notes:
    
    * `and_return`, `and_raise` and `and_throw` are "terminal" actions
      in the sense that they terminate the method. They _must_ happen last
      and it is impossible to support more than one of these. Hence, we allow
      only one of these, and allow them to be overridden. We also return `nil`
      from these methods to discourage further stub configuration.
    * `and_call_original` is a special case that doesn't make sense to be
      combined with any of the others. Once you've set it up, this causes
      any further instructions to raise an error.
    * `and_yield` is treated as an "initial" action. Yielding doesn't exit
      a method the way the terminal actions do. It is the only initial action.
      Calling it multiple times sets up multiple yields.
    * Setting a block implementation (possible by passing a block to almost
      any method on the fluent interface) sets the block as the "inner" action.
      It runs between the configured yields (if there are any) and the configured
      terminal action (if there is one). My thinking here is that in many cases,
      users use a block implementation to specify a return value, essentially
      making it like a terminal action (so it should come after the `and_yield`
      actions), but in other cases, the user may just use a block for a side
      effect, and may configure an terminal action as well. Only one block
      implementation is supported and it can be overridden.
Commits on Mar 16, 2013
  1. @myronmarston

    Refactor implementation pieces in prep for #230.

    myronmarston authored
    This splits each implementation piece into a separate object
    so that it is easier to combine them.
  2. @myronmarston
  3. @myronmarston

    Changelog entry for #242.

    myronmarston authored
    [ci skip]
  4. @myronmarston

    This is a bug fix, not a deprecation.

    myronmarston authored
    [ci skip]
  5. @myronmarston

    Merge pull request #242 from JonRowe/deprectate_stub_bang_and_unstub_…

    myronmarston authored
    …bang
    
    Deprecate #stub! and #unstub!
Commits on Mar 15, 2013
  1. @JonRowe

    deprecate unstub!

    JonRowe authored
  2. @JonRowe

    deprecate stub!

    JonRowe authored
Commits on Mar 12, 2013
  1. @myronmarston

    Fix travis CI build.

    myronmarston authored
    Fix travis CI build.
    
    - Bundler 1.3 needs rbconfig to be required to run `bin/rspec` after
      installing with `--standalone --binstubs`.
      bundler/bundler#2382
    - The Travis VMs no longer have 32-bit JVMs available. Aruba 0.4.11
      forced the -d32 flag. 0.5 just documents it and makes a file available
      to require that will set it. We've updated Aruba here so that the jruby
      ENV vars aren't set automatically; we've kept the flag to disable JIT
      but removed -d32.
Commits on Mar 6, 2013
  1. @myronmarston
Commits on Mar 4, 2013
  1. @myronmarston

    Changelog for #234.

    myronmarston authored
    [ci skip]
  2. @myronmarston

    Merge pull request #234 from JonRowe/fix_issue_with_stubbing_any_inst…

    myronmarston authored
    …ance_and_dup
    
    Fix issue #229 runtime error caused by duplicating an object which is frozen and stubbing with any_instance
  3. @JonRowe
Commits on Mar 3, 2013
  1. @JonRowe

    move resetting the mock proxy to the duplicate object, this fixes the…

    JonRowe authored
    … bizare issue with dup and frozen
  2. @JonRowe

    whitespace trim

    JonRowe authored
Commits on Mar 1, 2013
  1. @myronmarston

    Update changelog for #233.

    myronmarston authored
    [ci skip]
  2. @myronmarston
  3. @michihuber
  4. @michihuber
Commits on Feb 28, 2013
  1. @myronmarston

    Merge pull request #232 from vfrride/patch-1

    myronmarston authored
    Uses secure RubyGems URL
  2. @vfrride

    Uses secure RubyGems URL

    vfrride authored
Commits on Feb 23, 2013
  1. @myronmarston

    2.13.0 release

    myronmarston authored
  2. @myronmarston
  3. @dchelimsky
  4. @dchelimsky
  5. @dchelimsky
Commits on Feb 21, 2013
  1. @myronmarston
Commits on Feb 18, 2013
  1. @myronmarston

    Better fix for SimpleDelegator subclasses (#219).

    myronmarston authored
    My last fix did not properly simulate SimpleDelegator since it mixes in
    a dup of Kernel and not Kernel itself.  This actually fixes it, and I
    also fixed `and_call_original` (which suffered from the same bug) for
    this case as well.
  2. @dchelimsky

    Only run example with BasicObject when BasicObject is defined.

    dchelimsky authored
    It's not in Ruby < 1.9.
  3. @myronmarston
  4. @myronmarston

    Add changelog entry for #223.

    myronmarston authored
    [ci skip]
  5. @myronmarston

    Merge pull request #223 from RyanonRails/unstub_any_instance

    myronmarston authored
    disallow unstub! on any_instance
  6. @myronmarston

    Rename MessageImplementation to Implementation.

    myronmarston authored
    See #221 (comment) for the surrounding discussion.
  7. @myronmarston
  8. @myronmarston

    Add changelog entry for #226.

    myronmarston authored
    [ci skip]
Something went wrong with that request. Please try again.