@@ -183,7 +183,7 @@ private TestExecutionListener[] retrieveTestExecutionListeners(Class<?> clazz) {
183
183
// Use defaults?
184
184
if (declaringClass == null ) {
185
185
if (logger .isDebugEnabled ()) {
186
- logger .debug ("@TestExecutionListeners is not present for class [" + clazz + "]: using defaults." );
186
+ logger .debug ("@TestExecutionListeners is not present for class [" + clazz . getName () + "]: using defaults." );
187
187
}
188
188
classesList .addAll (getDefaultTestExecutionListenerClasses ());
189
189
}
@@ -193,15 +193,15 @@ private TestExecutionListener[] retrieveTestExecutionListeners(Class<?> clazz) {
193
193
TestExecutionListeners testExecutionListeners = declaringClass .getAnnotation (annotationType );
194
194
if (logger .isTraceEnabled ()) {
195
195
logger .trace ("Retrieved @TestExecutionListeners [" + testExecutionListeners +
196
- "] for declaring class [" + declaringClass + "]." );
196
+ "] for declaring class [" + declaringClass . getName () + "]." );
197
197
}
198
198
199
199
Class <? extends TestExecutionListener >[] valueListenerClasses = testExecutionListeners .value ();
200
200
Class <? extends TestExecutionListener >[] listenerClasses = testExecutionListeners .listeners ();
201
201
if (!ObjectUtils .isEmpty (valueListenerClasses ) && !ObjectUtils .isEmpty (listenerClasses )) {
202
202
throw new IllegalStateException (String .format ("Class [%s] configured with @TestExecutionListeners' " +
203
203
"'value' [%s] and 'listeners' [%s] attributes. Use one or the other, but not both." ,
204
- declaringClass , ObjectUtils .nullSafeToString (valueListenerClasses ),
204
+ declaringClass . getName () , ObjectUtils .nullSafeToString (valueListenerClasses ),
205
205
ObjectUtils .nullSafeToString (listenerClasses )));
206
206
}
207
207
else if (!ObjectUtils .isEmpty (valueListenerClasses )) {
@@ -279,7 +279,7 @@ protected Set<Class<? extends TestExecutionListener>> getDefaultTestExecutionLis
279
279
public void beforeTestClass () throws Exception {
280
280
Class <?> testClass = getTestContext ().getTestClass ();
281
281
if (logger .isTraceEnabled ()) {
282
- logger .trace ("beforeTestClass(): class [" + testClass + "]" );
282
+ logger .trace ("beforeTestClass(): class [" + testClass . getName () + "]" );
283
283
}
284
284
getTestContext ().updateState (null , null , null );
285
285
@@ -393,8 +393,8 @@ public void beforeTestMethod(Object testInstance, Method testMethod) throws Exce
393
393
public void afterTestMethod (Object testInstance , Method testMethod , Throwable exception ) throws Exception {
394
394
Assert .notNull (testInstance , "testInstance must not be null" );
395
395
if (logger .isTraceEnabled ()) {
396
- logger .trace ("afterTestMethod(): instance [" + testInstance + "], method [" + testMethod + "], exception ["
397
- + exception + "]" );
396
+ logger .trace ("afterTestMethod(): instance [" + testInstance + "], method [" + testMethod +
397
+ "], exception [" + exception + "]" );
398
398
}
399
399
getTestContext ().updateState (testInstance , testMethod , exception );
400
400
@@ -436,7 +436,7 @@ public void afterTestMethod(Object testInstance, Method testMethod, Throwable ex
436
436
public void afterTestClass () throws Exception {
437
437
Class <?> testClass = getTestContext ().getTestClass ();
438
438
if (logger .isTraceEnabled ()) {
439
- logger .trace ("afterTestClass(): class [" + testClass + "]" );
439
+ logger .trace ("afterTestClass(): class [" + testClass . getName () + "]" );
440
440
}
441
441
getTestContext ().updateState (null , null , null );
442
442
0 commit comments