From f046e1c6654b6d3d7c0f4619fab922445b457967 Mon Sep 17 00:00:00 2001 From: huangguojie2024 <503601315@qq.com> Date: Sat, 1 Feb 2025 00:22:10 +0800 Subject: [PATCH] Fixed the assertion failure. --- .../bigtop/manager/server/config/ValidatorConfigTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bigtop-manager-server/src/test/java/org/apache/bigtop/manager/server/config/ValidatorConfigTest.java b/bigtop-manager-server/src/test/java/org/apache/bigtop/manager/server/config/ValidatorConfigTest.java index 1e487033..61db071e 100644 --- a/bigtop-manager-server/src/test/java/org/apache/bigtop/manager/server/config/ValidatorConfigTest.java +++ b/bigtop-manager-server/src/test/java/org/apache/bigtop/manager/server/config/ValidatorConfigTest.java @@ -46,9 +46,9 @@ public void testFailFast() { // Since failFast is enabled, there should be only one error assertEquals(1, violations.size()); - // Check the error message + // Check the error field ConstraintViolation violation = violations.iterator().next(); - assertTrue(violation.getMessage().contains("must not be blank")); + assertEquals("field1", violation.getPropertyPath().toString()); } // Define a class with multiple validation constraints