test/must_test.rb in maiha-must-0.1 vs test/must_test.rb in maiha-must-0.2

- old
+ new

@@ -18,13 +18,15 @@ def test_must_be_with_block assert_equal :error, 1.must.be(2) {:error} end def test_must_not_be_blank - assert_equal "ok", "ok".must.not.be.blank - assert_equal "ok", "ok".must.not.be.blank {"ng"} - assert_equal "ng", "".must.not.be.blank {"ng"} - assert_raises(Invalid) {"".must.not.be.blank} + if Object.instance_methods.include?("blank?") + assert_equal "ok", "ok".must.not.be.blank + assert_equal "ok", "ok".must.not.be.blank {"ng"} + assert_equal "ng", "".must.not.be.blank {"ng"} + assert_raises(Invalid) {"".must.not.be.blank} + end end end class CoercedTest < Test::Unit::TestCase