Skip to content

Commit

Permalink
Improve AutomationIntegrationJsonTest
Browse files Browse the repository at this point in the history
Signed-off-by: Jan N. Klug <[email protected]>
  • Loading branch information
J-N-K committed Aug 16, 2023
1 parent aef57ed commit 19ad642
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ public void receive(Event e) {
}

@Test
public void assertThatARuleFromJsonFileIsExecutedCorrectly() throws ItemNotFoundException {
public void assertThatARuleFromJsonFileIsExecutedCorrectly() throws ItemNotFoundException, InterruptedException {
logger.info("assert that rule added by json is executed correctly");
waitForAssert(() -> {
assertThat(ruleRegistry.getAll().isEmpty(), is(false));
Expand Down Expand Up @@ -378,6 +378,7 @@ public void receive(Event e) {
};

registerService(eventHandler);
Thread.sleep(1000);
eventPublisher.post(ItemEventFactory.createStateEvent("myMotionItem", OnOffType.ON));
waitForAssert(() -> {
assertThat(itemEvent, is(notNullValue()));
Expand Down

0 comments on commit 19ad642

Please sign in to comment.