Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Switched to allowing a more canonical require statement

    require "shoulda/context"  # canonical

-vs-

    require "shoulda-context"  # still allowed

See comments of http://blog.segment7.net/2010/11/15/how-to-name-gems
  • Loading branch information...
commit ddb7d576996e9bca9369998b66c548c682f09249 1 parent 2c66aa8
@rmm5t rmm5t authored
View
13 lib/shoulda-context.rb
@@ -1,12 +1 @@
-require 'test/unit'
-require 'shoulda/context/version'
-require 'shoulda/context/proc_extensions'
-require 'shoulda/context/assertions'
-require 'shoulda/context/context'
-require 'shoulda/context/autoload_macros'
-
-class Test::Unit::TestCase
- include Shoulda::Context::Assertions
- include Shoulda::Context::InstanceMethods
- extend Shoulda::Context::ClassMethods
-end
+require "shoulda/context"
View
12 lib/shoulda/context.rb
@@ -0,0 +1,12 @@
+require 'test/unit'
+require 'shoulda/context/version'
+require 'shoulda/context/proc_extensions'
+require 'shoulda/context/assertions'
+require 'shoulda/context/context'
+require 'shoulda/context/autoload_macros'
+
+class Test::Unit::TestCase
+ include Shoulda::Context::Assertions
+ include Shoulda::Context::InstanceMethods
+ extend Shoulda::Context::ClassMethods
+end
View
2  rails/init.rb
@@ -1,4 +1,4 @@
if RAILS_ENV == 'test'
- require 'shoulda-context'
+ require "shoulda/context"
Shoulda.autoload_macros RAILS_ROOT, File.join("vendor", "{plugins,gems}", "*")
end
View
2  test/test_helper.rb
@@ -4,7 +4,7 @@
shoulda_path = File.join(File.dirname(__FILE__), '..', 'lib')
$LOAD_PATH << shoulda_path
-require 'shoulda-context'
+require "shoulda/context"
Shoulda.autoload_macros File.join(File.dirname(__FILE__), 'fake_rails_root'),
File.join("vendor", "{plugins,gems}", "*")
Please sign in to comment.
Something went wrong with that request. Please try again.