View Javadoc
1   /**
2    * 
3    */
4   package org.melati.poem.test;
5   
6   import org.melati.poem.DisplayLevel;
7   import org.melati.poem.DisplayLevel.NameUnrecognisedException;
8   
9   import junit.framework.TestCase;
10  
11  /**
12   * @author timp
13   * @since 2 Jan 2007
14   *
15   */
16  public class DisplayLevelTest extends TestCase {
17  
18    public DisplayLevelTest(String name) {
19      super(name);
20    }
21  
22    protected void setUp() throws Exception {
23      super.setUp();
24    }
25  
26    protected void tearDown() throws Exception {
27      super.tearDown();
28    }
29  
30    /**
31     * Test method for {@link org.melati.poem.DisplayLevel#forIndex(int)}.
32     */
33    public void testForIndex() {
34    }
35  
36    /**
37     * Test method for {@link org.melati.poem.DisplayLevel#count()}.
38     */
39    public void testCount() {
40    }
41  
42    /**
43     * Test method for {@link org.melati.poem.DisplayLevel#named(java.lang.String)}.
44     */
45    public void testNamed() {
46      assertEquals(DisplayLevel.primary,DisplayLevel.named("primary"));
47      try {
48        DisplayLevel.named("unknown");
49        fail("Should have blown up");
50      } catch (NameUnrecognisedException e) {
51        e = null;
52      }
53    }
54  
55    /**
56     * Test method for {@link org.melati.poem.DisplayLevel#toString()}.
57     */
58    public void testToString() {
59      assertEquals("primary/0",DisplayLevel.named("primary").toString());
60    }
61  
62  }