From 78ad4f13b288095acc67e2abc405c4466c6d6b8b Mon Sep 17 00:00:00 2001 From: raghucssit Date: Mon, 15 Sep 2025 14:06:36 +0200 Subject: [PATCH] Improve Display test assert message. --- .../tests/junit/Test_org_eclipse_swt_widgets_Display.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/org.eclipse.swt.tests/JUnit Tests/org/eclipse/swt/tests/junit/Test_org_eclipse_swt_widgets_Display.java b/tests/org.eclipse.swt.tests/JUnit Tests/org/eclipse/swt/tests/junit/Test_org_eclipse_swt_widgets_Display.java index 00c101f86f..11a67f30d0 100644 --- a/tests/org.eclipse.swt.tests/JUnit Tests/org/eclipse/swt/tests/junit/Test_org_eclipse_swt_widgets_Display.java +++ b/tests/org.eclipse.swt.tests/JUnit Tests/org/eclipse/swt/tests/junit/Test_org_eclipse_swt_widgets_Display.java @@ -342,8 +342,10 @@ public void test_getCursorLocation() { try { Point pt = display.getCursorLocation(); assertNotNull(pt); - assertTrue(pt.x >= 0); - assertTrue(pt.y >= 0); + assertTrue(pt.x >= 0, + "Display's cursor location x co-ordinate should be positive. But it is: " + pt.x); + assertTrue(pt.y >= 0, + "Display's cursor location y co-ordinate should be positive. But it is: " + pt.y); } finally { display.dispose(); }