require_relative 'test_helper' class TestTerm < MiniTest::Unit::TestCase def test_initializer assert_equal 0, Term.new.coefficient assert_equal 0, Term.new.exponent end def test_parsing assert_equal 4, Term.parse('4x^2').coefficient assert_equal 2, Term.parse('4x^2').exponent end end