1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
|
Description: Fix tests with ruby2.3
This test use TrueClass and your public methods to generate a TestTrueClass.
From ruby2.2 to ruby2.3 have some changes in public methods, in ruby2.3 have
'===' (equals3) method and ruby2.2 do not have it. So the test is removed,
because it will fail in one of the ruby version at least.
Author: Lucas Kanashiro <kanashiro.duarte@gmail.com>
Last-Updated: 2016-03-01
Forward: no
Bug: https://github.com/seattlerb/zentest/issues/66
--- a/test/test_zentest.rb
+++ b/test/test_zentest.rb
@@ -553,20 +553,4 @@ assert_equal expected, util_testcase("So
assert_equal expected, util_testcase("MyClass8")
end
-
- def test_testcase9
- skip "doesn't define to_s on TrueClass?!?" if maglev?
-
- # stupid YAML is breaking my tests. Enters via Test::Rails. order dependent.
- if defined? YAML then
- TrueClass.send :remove_method, :taguri, :taguri=, :to_yaml rescue nil
- end
-
- pims = TrueClass.public_instance_methods(false)
- TrueClass.send :remove_method, :inspect if pims.include? :inspect # 2.0 only
-
- expected = "#{HEADER}class TestTrueClass < Minitest::Test\n def test_and\n raise NotImplementedError, 'Need to write test_and'\n end\n\n def test_carat\n raise NotImplementedError, 'Need to write test_carat'\n end\n\n def test_or\n raise NotImplementedError, 'Need to write test_or'\n end\n\n def test_to_s\n raise NotImplementedError, 'Need to write test_to_s'\n end\nend\n\n# Number of errors detected: 4"
-
- assert_equal expected, util_testcase("TestTrueClass")
- end
end
|