Permalink
Browse files

Don't create new directory for tests

  • Loading branch information...
1 parent 5a2fdaa commit 1823d53d7bfa1625fb146c56e12a586aac7426fc @drogus drogus committed Apr 28, 2012
Showing with 24 additions and 26 deletions.
  1. +24 −0 railties/test/engine_test.rb
  2. +0 −26 railties/test/unit/engine_test.rb
@@ -0,0 +1,24 @@
+require 'abstract_unit'
+
+class EngineTest < ActiveSupport::TestCase
+ it "reports routes as available only if they're actually present" do
+ engine = Class.new(Rails::Engine) do
+ def initialize(*args)
+ @routes = nil
+ super
+ end
+ end
+
+ assert !engine.routes?
+ end
+
+ it "does not add more paths to routes on each call" do
+ engine = Class.new(Rails::Engine)
+
+ engine.routes
+ length = engine.routes.draw_paths.length
+
+ engine.routes
+ assert_equal length, engine.routes.draw_paths.length
+ end
+end
@@ -1,26 +0,0 @@
-require 'abstract_unit'
-
-module Unit
- class EngineTest < ActiveSupport::TestCase
- it "reports routes as available only if they're actually present" do
- engine = Class.new(Rails::Engine) do
- def initialize(*args)
- @routes = nil
- super
- end
- end
-
- assert !engine.routes?
- end
-
- it "does not add more paths to routes on each call" do
- engine = Class.new(Rails::Engine)
-
- engine.routes
- length = engine.routes.draw_paths.length
-
- engine.routes
- assert_equal length, engine.routes.draw_paths.length
- end
- end
-end

0 comments on commit 1823d53

Please sign in to comment.