From 68c17cd7e9b0dac099268c42f75270bb63015fb5 Mon Sep 17 00:00:00 2001 From: Johannes Eriksson Date: Fri, 11 Mar 2022 09:33:29 +0200 Subject: [PATCH] Add assert, fix comment --- .../test/java/com/vaadin/flow/uitest/ui/ModalDialogIT.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/flow-tests/test-root-context/src/test/java/com/vaadin/flow/uitest/ui/ModalDialogIT.java b/flow-tests/test-root-context/src/test/java/com/vaadin/flow/uitest/ui/ModalDialogIT.java index 93417b9af37..5440927a9db 100644 --- a/flow-tests/test-root-context/src/test/java/com/vaadin/flow/uitest/ui/ModalDialogIT.java +++ b/flow-tests/test-root-context/src/test/java/com/vaadin/flow/uitest/ui/ModalDialogIT.java @@ -58,10 +58,12 @@ public void modalDialogOpenInitially_dialogClosed_shortcutsInViewTrigger() { // shortcuts on view should not trigger while dialog is open pressShortcutKey( $(NativeButtonElement.class).id(ModalDialogView.UI_BUTTON)); + Assert.assertTrue("No event should be logged", + eventLog.$(DivElement.class).all().isEmpty()); closeDialog(); - // shortcuts on view should not trigger when dialog has been closed + // shortcuts on view should trigger when dialog has been closed pressShortcutKey( $(NativeButtonElement.class).id(ModalDialogView.UI_BUTTON)); validateLatestShortcutEvent(0, ModalDialogView.UI_BUTTON);