* @version $Id: FieldTest.java,v 1.3 2004/10/25 07:26:47 ntherning Exp $
*/
public class FieldTest extends TestCase {
public void testGetName() throws Exception {
Field f = null;
f = Field.parse("Subject: Yada yada yada");
assertEquals("Testing simple field", "Subject", f.getName());
f = Field.parse("X-yada-yada: Yada yada yada");
assertEquals("Testing an X- field", "X-yada-yada", f.getName());
try {
f = Field.parse("Yada yada yada");
fail("MimeException not thrown when using an invalid "
+ "field");