1 16 package org.apache.commons.net.telnet; 17 18 import junit.framework.TestCase; 19 20 25 public class InvalidTelnetOptionExceptionTest extends TestCase 26 { 27 private InvalidTelnetOptionException exc1; 28 private String msg1; 29 private int code1; 30 31 34 public static void main(String args[]) 35 { 36 junit.textui.TestRunner.run(InvalidTelnetOptionExceptionTest.class); 37 } 38 39 42 protected void setUp() 43 { 44 msg1 = new String ("MSG"); 45 code1 = 13; 46 exc1 = new InvalidTelnetOptionException(msg1, code1); 47 } 48 49 52 public void testConstructors() 53 { 54 assertTrue(exc1.getMessage().indexOf(msg1) >= 0); 55 assertTrue(exc1.getMessage().indexOf("" +code1) >= 0); 56 } 57 } | Popular Tags |