Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Minitest and Test::Unit

Due to all of the discussion in the open source community regarding TDD, I have read some blogs about the simplicity of Minitest. I currently use Rspec and think Minitest may be a good testing suite to learn. I feel silly asking this, but is Minitest the same as Test::Unit? I looked around online but I can't find the answer to this question. I want to ensure that when I talk about this, I at least ask the question correctly. So the real question is this:

Is Minitest the same as Test::Unit, or is Test::Unit a component of Minitest? If neither of those options, are they two totally different testing suites?

like image 566
dingalingchickenwiing Avatar asked Apr 18 '26 18:04

dingalingchickenwiing


1 Answers

Basically, Test::Unit got replaced by MiniTest (which ships with Ruby now). MiniTest tests can be written in the Test::Unit syntax or in the MiniTest::Spec syntax. Mini::Test, as a standalone, doesn't have a future... but MiniTest is faster, smaller, included by default, and has a great future and, IMHO, you should definitely make the switch! Although it is definitely lacking in documentation, as you have found. For the most part, you can just use Test::Unit documentation for help with using MiniTest.

like image 67
pdobb Avatar answered Apr 20 '26 10:04

pdobb