@Test
public void testE131Config() {
Properties config = new Properties();
config.put(ConfigConstant.E131_IP, "192.168.1.1");
config.put(ConfigConstant.E131_ROW1, "NO_ROTATE");
ApplicationConfigurationHelper ph = new ApplicationConfigurationHelper(config);
assertEquals(1, ph.getNrOfScreens());
assertEquals(8, ph.getDeviceXResolution());
assertEquals(8, ph.getDeviceYResolution());
assertEquals(false, ph.isOutputSnakeCabeling());
assertEquals(0, ph.getI2cAddr().size());
assertEquals(0, ph.getLpdDevice().size());
assertEquals(OutputDeviceEnum.E1_31, ph.getOutputDevice());
E1_31Device device = new E1_31Device(ph, 1);
assertFalse(device.isSendMulticast());
assertEquals(170, device.getPixelsPerUniverse());
assertEquals(1, device.getNrOfUniverse());
assertEquals(0, device.getFirstUniverseId());
config = new Properties();
config.put(ConfigConstant.E131_IP, "239.255.1.1");
config.put(ConfigConstant.E131_ROW1, "NO_ROTATE");
config.put(ConfigConstant.E131_FIRST_UNIVERSE_ID, "1");
config.put(ConfigConstant.E131_PIXELS_PER_UNIVERSE, "333");
config.put(ConfigConstant.OUTPUT_DEVICE_RESOLUTION_X, "10");
config.put(ConfigConstant.OUTPUT_DEVICE_SNAKE_CABELING, "true");
ph = new ApplicationConfigurationHelper(config);
assertEquals(OutputDeviceEnum.E1_31, ph.getOutputDevice());
assertEquals(1, ph.getNrOfScreens());
assertEquals(10, ph.getDeviceXResolution());
assertEquals(8, ph.getDeviceYResolution());
assertEquals(true, ph.isOutputSnakeCabeling());
assertEquals(0, ph.getI2cAddr().size());
assertEquals(0, ph.getLpdDevice().size());
assertEquals(OutputDeviceEnum.E1_31, ph.getOutputDevice());
device = new E1_31Device(ph, 1);
assertTrue(device.isSendMulticast());
assertEquals(1, device.getFirstUniverseId());
assertEquals(170, device.getPixelsPerUniverse());