47 lines
1.3 KiB
Java
47 lines
1.3 KiB
Java
package jmri.jmrix.srcp.swing;
|
|
|
|
import jmri.jmrix.srcp.SRCPListener;
|
|
import jmri.jmrix.srcp.SRCPMessage;
|
|
import jmri.jmrix.srcp.SRCPSystemConnectionMemo;
|
|
import jmri.jmrix.srcp.SRCPTrafficController;
|
|
import jmri.util.JUnitUtil;
|
|
|
|
import org.junit.Assert;
|
|
import org.junit.jupiter.api.*;
|
|
|
|
/**
|
|
*
|
|
* @author Paul Bender Copyright (C) 2017
|
|
*/
|
|
public class SRCPComponentFactoryTest {
|
|
|
|
private SRCPSystemConnectionMemo m = null;
|
|
|
|
@Test
|
|
public void testCTor() {
|
|
SRCPComponentFactory t = new SRCPComponentFactory(m);
|
|
Assert.assertNotNull("exists",t);
|
|
}
|
|
|
|
@BeforeEach
|
|
public void setUp() {
|
|
JUnitUtil.setUp();
|
|
SRCPTrafficController et = new SRCPTrafficController() {
|
|
@Override
|
|
public void sendSRCPMessage(SRCPMessage m, SRCPListener l) {
|
|
// we aren't actually sending anything to a layout.
|
|
}
|
|
};
|
|
m = new SRCPSystemConnectionMemo(et);
|
|
}
|
|
|
|
@AfterEach
|
|
public void tearDown() {
|
|
JUnitUtil.clearShutDownManager(); // put in place because AbstractMRTrafficController implementing subclass was not terminated properly
|
|
JUnitUtil.tearDown();
|
|
}
|
|
|
|
// private static final Logger log = LoggerFactory.getLogger(SRCPComponentFactoryTest.class);
|
|
|
|
}
|