2003-09-04 16:18:59 +00:00
|
|
|
require 'test/unit'
|
|
|
|
|
|
|
|
class TestMath < Test::Unit::TestCase
|
|
|
|
def test_math
|
2003-09-05 15:15:43 +00:00
|
|
|
assert_equal(2, Math.sqrt(4))
|
|
|
|
|
2003-09-04 16:18:59 +00:00
|
|
|
self.class.class_eval {
|
|
|
|
include Math
|
|
|
|
}
|
2003-09-05 15:15:43 +00:00
|
|
|
assert_equal(2, sqrt(4))
|
2003-09-04 16:18:59 +00:00
|
|
|
end
|
|
|
|
end
|