Last change
on this file since 2825 was
2825,
checked in by Pascal Terjan, 12 years ago
|
- No need to require test/unit in each testfile
|
File size:
423 bytes
|
Line | |
---|
1 | require 'caca' |
---|
2 | |
---|
3 | class TC_Canvas < Test::Unit::TestCase |
---|
4 | def test_list |
---|
5 | assert_not_nil(Caca::Font.list) |
---|
6 | end |
---|
7 | def test_load |
---|
8 | Caca::Font.list.each{|f| |
---|
9 | font = Caca::Font.new(f) |
---|
10 | assert_not_nil(font) |
---|
11 | assert_not_nil(font.width) |
---|
12 | assert_not_nil(font.height) |
---|
13 | assert_not_nil(font.blocks) |
---|
14 | } |
---|
15 | end |
---|
16 | def test_fail_load |
---|
17 | assert_raise(RuntimeError) { |
---|
18 | Caca::Font.new("This font should not exist") |
---|
19 | } |
---|
20 | end |
---|
21 | end |
---|
Note: See
TracBrowser
for help on using the repository browser.