From d148513e963110f406a850d3dba886847d49d46a Mon Sep 17 00:00:00 2001 From: Brady Bouchard Date: Thu, 1 Sep 2011 23:08:01 +1000 Subject: [PATCH] Moved to simplecov instead of rcov for Ruby 1.9.x. --- .gitignore | 1 + Gemfile | 10 +++++----- Rakefile | 11 ++--------- VERSION | 2 +- test/{helper.rb => test_helper.rb} | 2 ++ test/test_thumbs_up.rb | 2 +- 6 files changed, 12 insertions(+), 16 deletions(-) rename test/{helper.rb => test_helper.rb} (98%) diff --git a/.gitignore b/.gitignore index c8993f8..4b89f1b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ *.gem pkg/* Gemfile.lock +coverage/ diff --git a/Gemfile b/Gemfile index c474297..6225586 100644 --- a/Gemfile +++ b/Gemfile @@ -1,13 +1,13 @@ source :rubygems -gem 'activerecord', '3.0.3' +gem 'activerecord' group :development do - gem "bundler", "~> 1.0.0" - gem "jeweler", "~> 1.5.2" - gem "rcov", ">= 0" + gem 'bundler' + gem 'jeweler' + gem 'simplecov' end group :test do - gem 'sqlite3-ruby', '1.3.2' + gem 'sqlite3' end \ No newline at end of file diff --git a/Rakefile b/Rakefile index 844fcc4..bc4649e 100644 --- a/Rakefile +++ b/Rakefile @@ -26,18 +26,11 @@ Jeweler::RubygemsDotOrgTasks.new require 'rake/testtask' Rake::TestTask.new(:test) do |test| test.libs << 'lib' << 'test' - test.pattern = 'test/**/test_*.rb' + test.test_files = Dir.glob("test/**/*_test.rb") test.verbose = true end -require 'rcov/rcovtask' -Rcov::RcovTask.new do |test| - test.libs << 'test' - test.pattern = 'test/**/test_*.rb' - test.verbose = true -end - -require 'rake/rdoctask' +require 'rdoc/task' Rake::RDocTask.new do |rdoc| version = File.exist?('VERSION') ? File.read('VERSION') : "" diff --git a/VERSION b/VERSION index 267577d..2b7c5ae 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.4.1 +0.4.2 diff --git a/test/helper.rb b/test/test_helper.rb similarity index 98% rename from test/helper.rb rename to test/test_helper.rb index 1e18ab2..1f8834b 100644 --- a/test/helper.rb +++ b/test/test_helper.rb @@ -1,3 +1,5 @@ +require 'simplecov' +SimpleCov.start require 'test/unit' $LOAD_PATH.unshift(File.dirname(__FILE__)) diff --git a/test/test_thumbs_up.rb b/test/test_thumbs_up.rb index 223dc72..26cc112 100644 --- a/test/test_thumbs_up.rb +++ b/test/test_thumbs_up.rb @@ -1,4 +1,4 @@ -require 'helper' +require File.join(File.expand_path(File.dirname(__FILE__)), 'test_helper') class TestThumbsUp < Test::Unit::TestCase def setup