想象一下我有一个这样的测试:
class MyUnitTest < Test::Unit::TestCase
def test_first
# test code here
end
def test_second
# test code here
end
def test_third
# test code here
end
end
我的测试用例具有破坏性,我需要在测试之间重新生成输入。因此,一次只运行一个测试用例会很有用。目前,我的方法是评论我不想执行的测试,但肯定有更好的方法吗?
因此,例如,如何仅test_first
在执行测试时运行?