@Test void testConfigure() { MaxLengthConstraint maxLengthConstraint = new MaxLengthConstraint(); MaxLength annotation = mock(MaxLength.class); int maxValue = 100; when(annotation.value()).thenReturn(maxValue); maxLengthConstraint.configure(annotation); assertEquals(maxValue, maxLengthConstraint.getMax()); }