github
Advanced Search
  • Home
  • Pricing and Signup
  • Explore GitHub
  • Blog
  • Login

rubyspec / rubyspec

  • Admin
  • Watch Unwatch
  • Fork
  • Your Fork
  • Pull Request
  • Download Source
    • 237
    • 39
  • Source
  • Commits
  • Network (39)
  • Issues (1)
  • Downloads (11)
  • Wiki (1)
  • Graphs
  • Branch: master

click here to add a description

click here to add a homepage

  • Branches (4)
    • gh-pages
    • master ✓
    • readruby
    • runpaint
  • Tags (11)
    • v0.7.6
    • v0.7.5
    • v0.7.4
    • v0.7.3
    • v0.7.2
    • v0.7.1
    • v0.7.0
    • v0.6.2
    • v0.6.1
    • v0.6.0
    • v0.5.0
Sending Request…
Enable Donations

Pledgie Donations

Once activated, we'll place the following badge in your repository's detail box:
Pledgie_example
This service is courtesy of Pledgie.

Executable specification for the Ruby programming language using RSpec syntax. — Read more

  cancel

http://rubyspec.org

  cancel
  • Private
  • Read-Only
  • HTTP Read-Only

This URL has Read+Write access

Do not use 1.9.2 in version strings. 
Brian Ford (author)
Tue Feb 09 12:13:11 -0800 2010
commit  fd45f5edc9eb849488d43fd88749ec7087260193
tree    2996018c649087a6e4ee921e49d9ec4427d045c8
parent  e9cf07499744dd37ab1de7f17a8e803b4d1da35c
rubyspec /
name age
history
message
file .gitignore Mon Feb 01 16:03:22 -0800 2010 Updated .gitignore for new Kernel#require specs. [Brian Ford]
file CHANGES.before-2008-05-10 Sat May 10 11:20:23 -0700 2008 Extracted the spec revision history from the Ru... [rue]
file LICENSE Sat May 17 00:12:15 -0700 2008 Update license info. [Brian Ford]
file README.markdown Sun May 24 11:15:49 -0700 2009 Add a README to make it easier for people to ge... [Hongli Lai (Phusion)]
file TODO Fri Sep 04 17:41:49 -0700 2009 TODO: Remove completed items. [runpaint]
directory command_line/ Tue Feb 02 06:05:55 -0800 2010 require shared/verbose. [akr]
directory core/ Tue Feb 09 15:55:08 -0800 2010 Do not use 1.9.2 in version strings. Notes: * ... [Brian Ford]
directory fixtures/ Mon Feb 01 16:03:39 -0800 2010 Rewrote Kernel[.#]load specs. Notes: * Removed... [Brian Ford]
directory language/ Tue Feb 09 15:55:08 -0800 2010 Do not use 1.9.2 in version strings. Notes: * ... [Brian Ford]
directory library/ Tue Feb 09 15:55:08 -0800 2010 Do not use 1.9.2 in version strings. Notes: * ... [Brian Ford]
directory nbproject/ Thu Jan 14 06:49:26 -0800 2010 Add command_line dir to Netbeans project [Vladimir Sizikov]
directory optional/ Fri Jan 01 15:00:08 -0800 2010 Mac OS X Tiger is obsolete. 'make' works withou... [BanzaiMan]
file ruby.1.8.mspec Mon Feb 08 18:17:50 -0800 2010 Enable features for 1.8 and 1.9 configurations. [Brian Ford]
file ruby.1.9.mspec Mon Feb 08 18:17:50 -0800 2010 Enable features for 1.8 and 1.9 configurations. [Brian Ford]
directory shared/ Tue Jan 26 04:20:02 -0800 2010 Tweak File.executable_real? specs on Windows. [Vladimir Sizikov]
file spec_helper.rb Mon Feb 08 18:17:50 -0800 2010 Require mspec version 1.5.16. [Brian Ford]
directory tags/ Mon Oct 05 08:13:40 -0700 2009 * purges obsolete tags * removes tags for passe... [yugui]
file version.rb Mon Jun 08 15:34:41 -0700 2009 Update version to 0.7.6 and require mspec 1.5.12. [Brian Ford]
README.markdown

About RubySpec

RubySpec is a project to write a complete, executable specification for the Ruby programming language. The goal is official recognition and support from all the organizations currently involved in Ruby implementations, such as MatzRuby (including YARV), JRuby, IronRuby, MacRuby, Ruby.NET and MagLev. The specs describe Ruby language syntax, core library classes, and standard library classes.

This project has a free-flowing commit bit policy. If you have had a patch accepted by any current Ruby implementation project, you can get a commit bit by referencing your patch. Anyone who submits an accepted patch to this project will also receive a commit bit. The only requirement is that you have a Github account.

  • RubySpec website
  • RubySpec Wiki with documentation
  • Github repository

Running RubySpec

The RubySpec specification files are written in Ruby, utilizing the MSpec testing framework, so you need to download MSpec in order to run the RubySpec suite. If you don't have MSpec yet, then go to a directory outside the RubySpec directory and check out its source code from Github:

$ cd /somewhere
$ git clone git://github.com/rubyspec/mspec.git
# MSpec is now available in /somewhere/mspec.

You should add the MSpec bin directory to your PATH for easy access. In this README we'll assume that the mspec command is in PATH.

$ export PATH=/somewhere/mspec/bin:$PATH

If you already have MSpec, then you should run git pull from the MSpec source directory from time to time, because RubySpec often utilizes the latest MSpec features.

By invoking the mspec command inside the RubySpec directory, it will run the entire RubySpec suite against the Ruby interpreter (named ruby) in your PATH:

$ cd /path-to-rubyspec
$ mspec

Running RubySpec against a specific Ruby interpreter

Use the -t option to specify the Ruby interpreter that you want to run RubySpec against. The argument may be a full path to the Ruby binary:

# Runs RubySpec against /opt/ruby-enterprise/bin/ruby
$ mspec -t /opt/ruby-enterprise/bin/ruby

The argument may also be a shortcut. For example, if you specify j, then MSpec will look for jruby in PATH and run RubySpec against that:

# Runs RubySpec against JRuby in PATH.
$ mspec -t j

See mspec --help for a list of possible -t shortcut values.

Running parts of the spec

To run a single spec file, pass the filename to MSpec, for example:

$ mspec core/kernel/kind_of_spec.rb

You can also pass a directory, in which case all specs in that directories will be run:

$ mspec core/kernel

Note however that passing a directory to MSpec may not always be a good idea, because some specs aren't supposed to be run against the active Ruby interpreter. For example, if you run mspec -t /usr/bin/ruby1.8 library, then MSpec will run the 1.9-specific library specs as well, even though you specified Ruby 1.8 as the Ruby interpreter. Instead, you can specify pseudo-directories, which are defined in ruby.1.8.mspec and ruby.1.9.mspec. These pseudo-directories only include files appropriate for the active Ruby interpreter.

$ mspec :core
$ mspec :library
$ mspec :language

More

For more documentation, e.g. with regard to writing specs, please visit the Wiki.

Blog | Support | Training | Contact | API | Status | Twitter | Help | Security
© 2010 GitHub Inc. All rights reserved. | Terms of Service | Privacy Policy
Powered by the Dedicated Servers and
Cloud Computing of Rackspace Hosting®
Dedicated Server