spec/spec_helper.rb in distribution-0.7.3 vs spec/spec_helper.rb in distribution-0.8.0
- old
+ new
@@ -1,11 +1,11 @@
-$:.unshift(File.dirname(__FILE__)+"/../lib")
+$LOAD_PATH.unshift(File.dirname(__FILE__) + '/../lib')
begin
require 'simplecov'
SimpleCov.start do
- add_filter "/spec/"
- add_group "Libraries", "lib"
+ add_filter '/spec/'
+ add_group 'Libraries', 'lib'
end
rescue LoadError
end
require 'rspec'
require 'distribution'
@@ -24,26 +24,25 @@
# Use the specified formatter
config.formatter = :documentation # :progress, :html, :textmate
end
module ExampleWithGSL
- def it_only_with_gsl(name,opts={},&block)
+ def it_only_with_gsl(name, opts = {}, &block)
it(name, opts) do
if Distribution.has_gsl?
instance_eval(&block)
else
- skip("Requires GSL")
+ skip('Requires GSL')
end
end
end
-
- def it_only_with_java(name,&block)
+
+ def it_only_with_java(name, &block)
it(name) do
if Distribution.has_java?
instance_eval(&block)
else
- skip("Requires Java")
+ skip('Requires Java')
end
end
end
-
end