Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix unit tests running twice

Echoe creates a test task that works exactly like the one explicitly specified
in the Rakefile. Remove the explicit test task.
  • Loading branch information...
commit 415b75bb57352bd1c62d6797ff7540e18763695b 1 parent ce4cf34
Ryan Tomayko rtomayko authored
Showing with 4 additions and 7 deletions.
  1. +4 −7 Rakefile
11 Rakefile
View
@@ -1,10 +1,13 @@
require 'rubygems'
-require 'rake/testtask'
require 'rake/rdoctask'
require 'echoe'
task :default => :test
+task :test do
+ ENV['SINATRA_ENV'] = 'test'
+end
+
Rake::RDocTask.new do |rd|
rd.main = "README.rdoc"
rd.rdoc_files += ["README.rdoc"]
@@ -12,11 +15,6 @@ Rake::RDocTask.new do |rd|
rd.rdoc_dir = 'doc'
end
-Rake::TestTask.new do |t|
- ENV['SINATRA_ENV'] = 'test'
- t.pattern = File.dirname(__FILE__) + "/test/*_test.rb"
-end
-
Echoe.new("sinatra") do |p|
p.author = "Blake Mizerany"
p.summary = "Classy web-development dressed in a DSL"
@@ -26,4 +24,3 @@ Echoe.new("sinatra") do |p|
p.install_message = "*** Be sure to checkout the site for helpful tips! sinatrarb.com ***"
p.include_rakefile = true
end
-
Please sign in to comment.
Something went wrong with that request. Please try again.