Fix issues with tests after core-changes (#12817)

Signed-off-by: Jan N. Klug <github@klug.nrw>
This commit is contained in:
J-N-K 2022-05-27 09:07:15 +02:00 committed by GitHub
parent 2403ffcb86
commit 87023da9e3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
16 changed files with 54 additions and 28 deletions

View File

@ -15,7 +15,6 @@ package org.openhab.binding.irobot.internal.handler;
import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertEquals;
import java.io.IOException; import java.io.IOException;
import java.lang.reflect.Field;
import org.eclipse.jdt.annotation.NonNullByDefault; import org.eclipse.jdt.annotation.NonNullByDefault;
import org.eclipse.jdt.annotation.Nullable; import org.eclipse.jdt.annotation.Nullable;
@ -38,9 +37,10 @@ import org.openhab.core.thing.ThingTypeUID;
import org.openhab.core.thing.ThingUID; import org.openhab.core.thing.ThingUID;
import org.openhab.core.thing.binding.ThingHandlerCallback; import org.openhab.core.thing.binding.ThingHandlerCallback;
import org.openhab.core.thing.internal.ThingImpl; import org.openhab.core.thing.internal.ThingImpl;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.slf4j.spi.LocationAwareLogger;
import ch.qos.logback.classic.Level;
import ch.qos.logback.classic.Logger;
/** /**
* Test the MQTT protocol with local iRobot (without openhab running). * Test the MQTT protocol with local iRobot (without openhab running).
@ -66,11 +66,8 @@ public class RoombaHandlerTest {
@BeforeEach @BeforeEach
void setUp() throws Exception { void setUp() throws Exception {
Logger logger = LoggerFactory.getLogger(RoombaHandler.class); final Logger logger = (Logger) LoggerFactory.getLogger(RoombaHandler.class);
Field logLevelField = logger.getClass().getDeclaredField("currentLogLevel"); logger.setLevel(Level.TRACE);
logLevelField.setAccessible(true);
logLevelField.set(logger, LocationAwareLogger.TRACE_INT);
Configuration config = new Configuration(); Configuration config = new Configuration();
config.put("ipaddress", RoombaHandlerTest.IP_ADDRESS); config.put("ipaddress", RoombaHandlerTest.IP_ADDRESS);
config.put("password", RoombaHandlerTest.PASSWORD); config.put("password", RoombaHandlerTest.PASSWORD);

View File

@ -53,9 +53,6 @@ public class Main {
try { try {
scheduler = Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessors()); scheduler = Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessors());
logger.info("System properties={}",
System.getProperties().get(org.slf4j.impl.SimpleLogger.DEFAULT_LOG_LEVEL_KEY));
ParadoxBuilderFactory factory = new ParadoxBuilderFactory(); ParadoxBuilderFactory factory = new ParadoxBuilderFactory();
ICommunicatorBuilder builder = factory.createBuilder(PanelType.EVO192); ICommunicatorBuilder builder = factory.createBuilder(PanelType.EVO192);
communicator = builder.withIp150Password(ip150Password).withPcPassword(pcPassword).withIpAddress(ipAddress) communicator = builder.withIp150Password(ip150Password).withPcPassword(pcPassword).withIpAddress(ipAddress)

View File

@ -75,4 +75,6 @@ Fragment-Host: org.openhab.binding.avmfritz
org.eclipse.jetty.websocket.common;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.websocket.common;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\ org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\
org.jupnp;version='[2.6.1,2.6.2)' org.jupnp;version='[2.6.1,2.6.2)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -75,4 +75,6 @@ Fragment-Host: org.openhab.binding.feed
org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-jetty;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-jetty;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-runtime;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-runtime;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-spi;version='[7.3.25,7.3.26)' org.ops4j.pax.web.pax-web-spi;version='[7.3.25,7.3.26)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -6,7 +6,8 @@ Fragment-Host: org.openhab.binding.hue
-runrequires: \ -runrequires: \
bnd.identity;id='org.openhab.binding.hue.tests',\ bnd.identity;id='org.openhab.binding.hue.tests',\
bnd.identity;id='org.openhab.core.binding.xml',\ bnd.identity;id='org.openhab.core.binding.xml',\
bnd.identity;id='org.openhab.core.thing.xml' bnd.identity;id='org.openhab.core.thing.xml',\
bnd.identity;id='org.eclipse.jdt.annotation'
# We would like to use the "volatile" storage only # We would like to use the "volatile" storage only
-runblacklist: \ -runblacklist: \
@ -21,7 +22,6 @@ Fragment-Host: org.openhab.binding.hue
org.osgi.service.event;version='[1.4.0,1.4.1)',\ org.osgi.service.event;version='[1.4.0,1.4.1)',\
org.hamcrest;version='[2.2.0,2.2.1)',\ org.hamcrest;version='[2.2.0,2.2.1)',\
org.opentest4j;version='[1.2.0,1.2.1)',\ org.opentest4j;version='[1.2.0,1.2.1)',\
org.eclipse.jdt.annotation;version='[2.2.100,2.2.101)',\
com.sun.xml.bind.jaxb-osgi;version='[2.3.3,2.3.4)',\ com.sun.xml.bind.jaxb-osgi;version='[2.3.3,2.3.4)',\
jakarta.xml.bind-api;version='[2.3.3,2.3.4)',\ jakarta.xml.bind-api;version='[2.3.3,2.3.4)',\
org.apache.servicemix.specs.activation-api-1.2.1;version='[1.2.1,1.2.2)',\ org.apache.servicemix.specs.activation-api-1.2.1;version='[1.2.1,1.2.2)',\
@ -79,4 +79,7 @@ Fragment-Host: org.openhab.binding.hue
org.eclipse.jetty.websocket.common;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.websocket.common;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\ org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\
org.jupnp;version='[2.6.1,2.6.2)' org.jupnp;version='[2.6.1,2.6.2)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)',\
org.eclipse.jdt.annotation;version='[2.2.100,2.2.101)'

View File

@ -66,4 +66,6 @@ Fragment-Host: org.openhab.binding.max
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -85,4 +85,6 @@ Fragment-Host: org.openhab.binding.mielecloud
org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-jetty;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-jetty;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-runtime;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-runtime;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-spi;version='[7.3.25,7.3.26)' org.ops4j.pax.web.pax-web-spi;version='[7.3.25,7.3.26)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -75,4 +75,6 @@ Fragment-Host: org.openhab.binding.modbus
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -109,4 +109,7 @@ Import-Package: \
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)',\
jakarta.ws.rs-api;version='[2.1.6,2.1.7)'

View File

@ -109,5 +109,8 @@ Import-Package: \
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)',\
jakarta.ws.rs-api;version='[2.1.6,2.1.7)'

View File

@ -10,7 +10,8 @@ Fragment-Host: org.openhab.binding.nest
# We would like to use the "volatile" storage only # We would like to use the "volatile" storage only
-runblacklist: \ -runblacklist: \
bnd.identity;id='org.openhab.core.storage.json' bnd.identity;id='org.openhab.core.storage.json',\
bnd.identity;id='jakarta.ws.rs-api'
# #
# done # done
@ -104,4 +105,6 @@ Fragment-Host: org.openhab.binding.nest
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\ org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-jetty;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-jetty;version='[7.3.25,7.3.26)',\
org.ops4j.pax.web.pax-web-spi;version='[7.3.25,7.3.26)' org.ops4j.pax.web.pax-web-spi;version='[7.3.25,7.3.26)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -70,4 +70,6 @@ Fragment-Host: org.openhab.binding.ntp
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -73,4 +73,6 @@ Fragment-Host: org.openhab.binding.systeminfo
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -76,4 +76,6 @@ Fragment-Host: org.openhab.binding.tradfri
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -83,4 +83,6 @@ Fragment-Host: org.openhab.binding.wemo
org.eclipse.jetty.websocket.common;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.websocket.common;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\ org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\ org.ops4j.pax.web.pax-web-api;version='[7.3.25,7.3.26)',\
org.jupnp;version='[2.6.1,2.6.2)' org.jupnp;version='[2.6.1,2.6.2)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'

View File

@ -57,4 +57,6 @@ Fragment-Host: org.openhab.persistence.mapdb
org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.servlet;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util;version='[9.4.46,9.4.47)',\
org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\ org.eclipse.jetty.util.ajax;version='[9.4.46,9.4.47)',\
org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)' org.ops4j.pax.logging.pax-logging-api;version='[2.0.16,2.0.17)',\
ch.qos.logback.classic;version='[1.2.11,1.2.12)',\
ch.qos.logback.core;version='[1.2.11,1.2.12)'