Hi,
test-unit 2.0.7 has been released:
http://test-unit.rubyforge.org/
Install:
% sudo gem install test-unit
Highlights:
This release includes redefined test method detection:
test-calc.rb:
require ‘rubygems’
gem ‘test-unit’
require ‘test/unit’
class CalcTest < Test::Unit::TestCase
def test_add
assert_equal(10000000, 1 + 2)
end
def test_add
assert_equal(3, 1 + 2)
end
end
% ruby test-calc.rb
Loaded suite test-calc
Started
N.
1) Notification: CalcTest#test_add was redefined
test_add(CalcTest)
test-calc.rb:10
Finished in 0.001629 seconds.
1 tests, 1 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions,
1 notifications
100% passed
NOTE:
This release include interface incompatible. Multiple --name
and --testcase command line options narrow down targets
instead of adding targets.
Before:
‘–testcase CalcTest --name test_sub’ means ‘runs CalcTest
test case and test_sub test’.
Now:
‘–testcase CalcTest --name test_sub’ means ‘runs test_sub
test in CalcTest test case’.
Description:
Test::Unit 2.x - Improved version of Test::Unit bundled in
Ruby 1.8.x.
Ruby 1.9.x bundles miniunit not Test::Unit. Test::Unit
bundled in Ruby 1.8.x had not been improved but unbundled
Test::Unit (Test::Unit 2.x) will be improved actively.
Changes:
-
4 major enhancements
- detect redefined test methods.
- [INTERFACE IMCOMPATIBLE] multiple --name and --testcase
options narrow down targets instead of adding targets. - [#27764] accept custom test_order for each test case.
[Suggested by David MARCHALAND] - [#27790] ignore omitted tests from ‘n% passed’ report.
[Suggested by Daniel B.]
-
2 minor enchancements
- [#27832] ignore .git directory. [Suggested by Daniel B.]
- [#27792] require ‘fileutils’ and ‘tmpdir’ lazily for non-priority
mode users. [Suggested by David MARCHALAND]
-
2n bug fixes
- [#27892] modify processed arguments array destructively.
[Reported by Bob Saveland] - work without HOME environment variable.
[Reported by Champak Ch]
- [#27892] modify processed arguments array destructively.
-
Thanks
- David MARCHALAND
- Daniel B.
- Bob Saveland
- Champak Ch
Thanks,