408771 Problem with ShutdownMonitor for jetty-ant

This commit is contained in:
Jan Bartel 2013-05-23 16:12:46 +10:00
parent 8ed25ec478
commit f825e27275
2 changed files with 10 additions and 8 deletions

View File

@ -278,6 +278,7 @@ public class ServerProxyImpl implements ServerProxy
}
catch (Exception e)
{
e.printStackTrace();
new RuntimeException(e);
}
}
@ -351,11 +352,14 @@ public class ServerProxyImpl implements ServerProxy
return;
configured = true;
ShutdownMonitor monitor = ShutdownMonitor.getInstance();
monitor.setPort(stopPort);
monitor.setKey(stopKey);
monitor.setExitVm(false);
if(stopPort>0 && stopKey!=null)
{
ShutdownMonitor monitor = ShutdownMonitor.getInstance();
monitor.setPort(stopPort);
monitor.setKey(stopKey);
monitor.setExitVm(false);
}
if (tempDirectory != null && !tempDirectory.exists())
tempDirectory.mkdirs();

View File

@ -30,8 +30,7 @@ import org.junit.Test;
public class JettyAntTaskTest
{
@Ignore
//@Test
@Test
public void testConnectorTask() throws Exception
{
AntBuild build = new AntBuild(MavenTestingUtils.getTestResourceFile("connector-test.xml").getAbsolutePath());
@ -51,7 +50,6 @@ public class JettyAntTaskTest
@Test
@Ignore("need to update connector")
public void testWebApp () throws Exception
{
AntBuild build = new AntBuild(MavenTestingUtils.getTestResourceFile("webapp-test.xml").getAbsolutePath());