1 37 package net.sourceforge.cruisecontrol.publishers; 38 39 import junit.framework.TestCase; 40 import net.sourceforge.cruisecontrol.CruiseControlException; 41 42 public class ExecutePublisherTest extends TestCase { 43 44 public void testValidate() { 45 ExecutePublisher publisher = new ExecutePublisher(); 46 try { 47 publisher.validate(); 48 fail("ExecutePublisher should throw exceptions when required fields are not set."); 49 } catch (CruiseControlException cce) { 50 } 51 52 publisher.setCommand("command"); 53 54 try { 55 publisher.validate(); 56 } catch (CruiseControlException e) { 57 fail("ExecutePublisher should not throw exceptions when required fields are set."); 58 } 59 } 60 } 61 | Popular Tags |