diff options
Diffstat (limited to 'test/test_mall.rb')
-rw-r--r-- | test/test_mall.rb | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/test_mall.rb b/test/test_mall.rb new file mode 100644 index 0000000..437b619 --- /dev/null +++ b/test/test_mall.rb @@ -0,0 +1,21 @@ +require "test/unit" +require "mall" + +class TestMall < Test::Unit::TestCase + + def test_mallinfo + assert Hash === Mall.info + Mall.info.each { |key,value| + assert Symbol === key + assert Fixnum === value + } + end + + def test_mallopt + Mall.constants.each { |konst| + rv = Mall.opt(Mall.const_get(konst), 0) + assert(TrueClass === rv || FalseClass === rv) + } + end + +end |