Permalink
Commits on Jan 12, 2010
  1. Add specs for Kernel.abort.

    benbc committed Jan 12, 2010
Commits on Jan 10, 2010
  1. Move one grpowned spec from shared place to FileTest

    vvs committed Jan 10, 2010
    This resolves one failure with MRI/JRuby.
  2. Additional spec for the Marshal.load method.

    mtyaka authored and headius committed Jan 10, 2010
    Signed-off-by: Charles Oliver Nutter <headius@headius.com>
Commits on Jan 9, 2010
Commits on Jan 8, 2010
  1. Add specs for Math.lgamma. Numerical values are based on MRI, which u…

    BanzaiMan committed Jan 8, 2010
    …ses lgamma_r() function from libmath.
  2. Add specs for Math.gamma. Numerical values are based on MRI, which us…

    BanzaiMan committed Jan 8, 2010
    …es tgamma() function from libmath.
Commits on Jan 7, 2010
Commits on Jan 6, 2010
  1. specs for front underscores

    kronos authored and Brian Ford committed Jan 6, 2010
    Closes #6.
    
    Signed-off-by: Brian Ford <bford@engineyard.com>
  2. Clean up flip-flop specs.

    Brian Ford
    Brian Ford committed Jan 6, 2010
    Note:
    * The use of #inject merely complicates the spec since the else
      branch of the #inject block is superfluous.
    * The examples each combined two distinct and quite different
      cases. Each example needs to cover a single facet of behavior.
  3. Simplify -e conditional range specs.

    Brian Ford
    Brian Ford committed Jan 6, 2010
    Note:
    * These specs do not run in <= 1.8.7p72, since 1.8.7p248 is current
      1.8.7 release, using that in the version guard.
    * Use the fixture() helper.
    * Extract and parameterize the command.
    * Remove extraneous #chomp call, the result string already has embedded
      newlines, the trailing newline is not an issue.
  4. Adding some specs for describing the conditional range notation.

    mrkn authored and Brian Ford committed Jan 6, 2010
    Signed-off-by: Brian Ford <bford@engineyard.com>
  5. Updated some ruby_bug guards for released 1.8.7p248.

    Brian Ford
    Brian Ford committed Jan 6, 2010
  6. Add spec for eval/__FILE__ stomping behavior

    Evan Phoenix Brian Ford
    Evan Phoenix authored and Brian Ford committed Jan 5, 2010
  7. Add a test that chdir should call to_str on an object if a block is g…

    Yehuda Katz Brian Ford
    Yehuda Katz authored and Brian Ford committed Jan 5, 2010
    …iven
  8. Require mspec v1.5.14.

    Brian Ford
    Brian Ford committed Jan 6, 2010
Commits on Jan 5, 2010
  1. Time.utc(1900, 12, 31, 23, 59, 59, 0) works fine on OS X Snow Leopard…

    FooBarWidget committed Jan 5, 2010
    …. Removing the code that tests it doesn't.
  2. Example: use variables and fs helpers.

    Brian Ford
    Brian Ford committed Jan 5, 2010
    Repeatedly using tmp(some_name) adds a lot of noise to the specs.
    Use variables to simplify them. Also use the file system helpers
    touch(), mkdir_p(), and rm_r() for creating and removing files and
    directories.
  3. Example: simplify complex specs.

    Brian Ford
    Brian Ford committed Jan 5, 2010
    Usually I am not a fan of specs like this one that loop over
    data in a single example. But there are situations like this
    that would be tedious if broken into multiple examples. However,
    sometimes it is best to break into multiple examples and add
    a special matcher to make the specs simpler.
    
    In this case, the file handling is moved into before/after
    actions, but the file contents are written for each item in
    the data being iterated. A separate describe block is wrapped
    in the version guard because there are likely many more 1.9-
    specific (or encoding-specific) specs that need to be added.
  4. Example: use before/after actions.

    Brian Ford
    Brian Ford committed Jan 5, 2010
    Do not use begin/ensure in specs unless testing begin/ensure
    or some extremely rare edge-case. The before/after actions
    run even if the spec fails. Always use before/after actions
    for setup/cleanup.
    
    Use the fixture() helper for locating the file names of fixture
    files.
  5. Example: use separate describe blocks when needed.

    Brian Ford
    Brian Ford committed Jan 5, 2010
    Other things to note:
    * Use consistent style in the specs. These mixed 3 different forms of blocks.
    * Use before/after actions for setting up fixture data and cleanup rather
      than embedding that in the example blocks as much as possible. In this case
      'read_size' has to be set up in the specific example, which is fine.
    * The original spec has confusing expectations: why trust @data.size but then
      do that funky split('').all? expectation? It makes no sense.
    * Avoid or at least document 'mystery math' in the specs. I still have no idea
      of the significance of those numbers for the @data size.
  6. Example: use touch helper.

    Brian Ford
    Brian Ford committed Jan 5, 2010
  7. Make sure io is closed after *every* IO#read test.

    vvs committed Jan 5, 2010
    Otherwise, they all will fail on Windows, since
    opened files can't be deleted.
    
    This reverts commit d461eb1.
  8. Use tmp helper for IO#pos specs

    vvs committed Jan 5, 2010