diff --git a/Rakefile b/Rakefile index f23d9d8e..8246b83c 100644 --- a/Rakefile +++ b/Rakefile @@ -4,7 +4,7 @@ require 'rake/rdoctask' Rake::TestTask.new do |t| t.libs << 'lib' - t.pattern = 'test/{unit,functional}/**/*_test.rb' # Update this line + t.pattern = 'test/{unit,functional,other}/**/*_test.rb' t.verbose = true end diff --git a/test/disabled/active_record_test.rb b/test/disabled/active_record_test.rb deleted file mode 100644 index aca9269a..00000000 --- a/test/disabled/active_record_test.rb +++ /dev/null @@ -1,54 +0,0 @@ -require File.join(File.dirname(__FILE__), '..', 'test_helper') - -class Post < ActiveRecord::Base - belongs_to :user - validates_uniqueness_of :title - validates_presence_of :title - validates_presence_of :body, :message => 'Seriously... wtf' - validates_numericality_of :user_id -end - -class User < ActiveRecord::Base - has_many :posts - has_many :taggings - has_many :tags, :through => :taggings - attr_protected :password - validates_format_of :email, :with => /\w*@\w*.com/ - validates_length_of :email, :in => 1..100 - validates_inclusion_of :age, :in => 1..100 -end - -class Tag < ActiveRecord::Base - has_many :taggings - has_many :users, :through => :taggings -end - -class Tagging < ActiveRecord::Base - belongs_to :user - belongs_to :tag -end - -class PostTest < Test::Unit::TestCase # :nodoc: - fixtures :posts - - should_belong_to :user - should_require_unique_attributes :title - - should_require_attributes :body, :message => /wtf/ - should_require_attributes :title - should_only_allow_numeric_values_for :user_id -end - -class UserTest < Test::Unit::TestCase # :nodoc: - fixtures :users - - should_have_many :posts - should_have_many :taggings - should_have_many :tags, :through => :taggings - - should_not_allow_values_for :email, "blah", "b lah" - should_allow_values_for :email, "a@b.com", "asdf@asdf.com" - should_ensure_length_in_range :email, 1..100 - should_ensure_value_in_range :age, 1..100 - should_protect_attributes :password -end \ No newline at end of file diff --git a/test/disabled/context_test.rb b/test/other/context_test.rb similarity index 79% rename from test/disabled/context_test.rb rename to test/other/context_test.rb index d46d78df..984ffd58 100644 --- a/test/disabled/context_test.rb +++ b/test/other/context_test.rb @@ -12,7 +12,7 @@ class ContextTest < Test::Unit::TestCase # :nodoc: end should "have name set right" do - assert_match(/^test context with setup block/, self.to_s) + assert_match(/^test: context with setup block/, self.to_s) end context "and a subcontext" do @@ -21,7 +21,7 @@ class ContextTest < Test::Unit::TestCase # :nodoc: end should "be named correctly" do - assert_match(/^test context with setup block and a subcontext should be named correctly/, self.to_s) + assert_match(/^test: context with setup block and a subcontext should be named correctly/, self.to_s) end should "run the setup methods in order" do @@ -40,7 +40,7 @@ class ContextTest < Test::Unit::TestCase # :nodoc: end should "have name set right" do - assert_match(/^test another context with setup block/, self.to_s) + assert_match(/^test: another context with setup block/, self.to_s) end end @@ -54,7 +54,7 @@ class ContextTest < Test::Unit::TestCase # :nodoc: end should "have name set right" do - assert_match(/^test context with method definition/, self.to_s) + assert_match(/^test: context with method definition/, self.to_s) end end diff --git a/test/disabled/helpers_test.rb b/test/other/helpers_test.rb similarity index 100% rename from test/disabled/helpers_test.rb rename to test/other/helpers_test.rb diff --git a/test/disabled/private_helpers_test.rb b/test/other/private_helpers_test.rb similarity index 100% rename from test/disabled/private_helpers_test.rb rename to test/other/private_helpers_test.rb