@@ -187,7 +187,7 @@ private TestExecutionListener[] retrieveTestExecutionListeners(Class<?> clazz) {
187
187
// Use defaults?
188
188
if (descriptor == null ) {
189
189
if (logger .isDebugEnabled ()) {
190
- logger .debug ("@TestExecutionListeners is not present for class [" + clazz + "]: using defaults." );
190
+ logger .debug ("@TestExecutionListeners is not present for class [" + clazz . getName () + "]: using defaults." );
191
191
}
192
192
classesList .addAll (getDefaultTestExecutionListenerClasses ());
193
193
}
@@ -198,7 +198,7 @@ private TestExecutionListener[] retrieveTestExecutionListeners(Class<?> clazz) {
198
198
AnnotationAttributes annAttrs = descriptor .getAnnotationAttributes ();
199
199
if (logger .isTraceEnabled ()) {
200
200
logger .trace (String .format ("Retrieved @TestExecutionListeners attributes [%s] for declaring class [%s]." ,
201
- annAttrs , declaringClass ));
201
+ annAttrs , declaringClass . getName () ));
202
202
}
203
203
204
204
Class <? extends TestExecutionListener >[] valueListenerClasses =
@@ -208,7 +208,7 @@ private TestExecutionListener[] retrieveTestExecutionListeners(Class<?> clazz) {
208
208
if (!ObjectUtils .isEmpty (valueListenerClasses ) && !ObjectUtils .isEmpty (listenerClasses )) {
209
209
throw new IllegalStateException (String .format ("Class [%s] configured with @TestExecutionListeners' " +
210
210
"'value' [%s] and 'listeners' [%s] attributes. Use one or the other, but not both." ,
211
- declaringClass , ObjectUtils .nullSafeToString (valueListenerClasses ),
211
+ declaringClass . getName () , ObjectUtils .nullSafeToString (valueListenerClasses ),
212
212
ObjectUtils .nullSafeToString (listenerClasses )));
213
213
}
214
214
else if (!ObjectUtils .isEmpty (valueListenerClasses )) {
@@ -289,7 +289,7 @@ protected Set<Class<? extends TestExecutionListener>> getDefaultTestExecutionLis
289
289
public void beforeTestClass () throws Exception {
290
290
Class <?> testClass = getTestContext ().getTestClass ();
291
291
if (logger .isTraceEnabled ()) {
292
- logger .trace ("beforeTestClass(): class [" + testClass + "]" );
292
+ logger .trace ("beforeTestClass(): class [" + testClass . getName () + "]" );
293
293
}
294
294
getTestContext ().updateState (null , null , null );
295
295
@@ -403,8 +403,8 @@ public void beforeTestMethod(Object testInstance, Method testMethod) throws Exce
403
403
public void afterTestMethod (Object testInstance , Method testMethod , Throwable exception ) throws Exception {
404
404
Assert .notNull (testInstance , "testInstance must not be null" );
405
405
if (logger .isTraceEnabled ()) {
406
- logger .trace ("afterTestMethod(): instance [" + testInstance + "], method [" + testMethod + "], exception ["
407
- + exception + "]" );
406
+ logger .trace ("afterTestMethod(): instance [" + testInstance + "], method [" + testMethod +
407
+ "], exception [" + exception + "]" );
408
408
}
409
409
getTestContext ().updateState (testInstance , testMethod , exception );
410
410
@@ -446,7 +446,7 @@ public void afterTestMethod(Object testInstance, Method testMethod, Throwable ex
446
446
public void afterTestClass () throws Exception {
447
447
Class <?> testClass = getTestContext ().getTestClass ();
448
448
if (logger .isTraceEnabled ()) {
449
- logger .trace ("afterTestClass(): class [" + testClass + "]" );
449
+ logger .trace ("afterTestClass(): class [" + testClass . getName () + "]" );
450
450
}
451
451
getTestContext ().updateState (null , null , null );
452
452
0 commit comments