An example of your code will be completed with the name of a NameError: uninitialized constant Minitest.
You have two options:
- Use
test/unitin combination with Test::Unit::TestCaseor - use
require 'minitest/autorun'in combination with Minitest::Test.
test/unit is outdated and it is recommended to use minitest (MiniTest is faster and less).
, , , :
require "test/unit" require "minitest/autorun"Test::Unit::TestCase with Minitest::Testassert_nothing_raised ()assert_raise assert_raises.- , .
require 'minitest' require 'minitest/autorun' - , . , (. minitest-a-test-suite-with-method-level-granularity)