1
0
Fork 0
mirror of https://github.com/rubyjs/therubyracer synced 2023-03-27 23:21:42 -04:00

update to rspec 2.0

This commit is contained in:
Charles Lowell 2010-10-26 10:49:23 -05:00
parent d53ee669cc
commit 9c4537b32c
4 changed files with 8 additions and 18 deletions

View file

@ -57,17 +57,17 @@ module V8
puts e.backtrace(:javascript)
rescue StandardError => e
puts e
end
end
end
def self.test
begin
require 'rubygems'
require 'spec'
parser = ::Spec::Runner::OptionParser.new($stderr, $stdout)
parser.order!([File.dirname(__FILE__) + '/../../spec/'])
::Spec::Runner.use(parser.options)
exit parser.options.run_examples
require 'rspec'
ARGV.clear
ARGV << File.dirname(__FILE__) + '/../../spec/'
::RSpec::Core::Runner.autorun
exit(0)
rescue LoadError => e
puts "selftest requires rspec to be installed (gem install rspec)"
exit(1)

View file

@ -1,10 +1,10 @@
begin
require 'spec'
require 'rspec'
rescue LoadError
require 'rubygems' unless ENV['NO_RUBYGEMS']
gem 'rspec'
require 'spec'
require 'rspec'
end
#

View file

@ -1,10 +0,0 @@
begin
require 'spec/rake/spectask'
Spec::Rake::SpecTask.new(:spec) do |spec|
spec.libs << 'lib' << 'spec'
spec.spec_files = FileList['spec/**/*_spec.rb']
end
task :spec => :compile
rescue LoadError => e
puts "unable to run specs from rake. gem install rspec"
end