From 0f85f52ddaa8bb0c5e6e2b2a17be908ae717151a Mon Sep 17 00:00:00 2001 From: Egon Willighagen Date: Tue, 20 Apr 2010 14:45:07 +0200 Subject: [PATCH] Be a bit more forthcoming with debug messages: report also the parameter types of the method Signed-off-by: Rajarshi Guha --- .../cdk/coverage/CoverageAnnotationTest.java | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/test/org/openscience/cdk/coverage/CoverageAnnotationTest.java b/src/test/org/openscience/cdk/coverage/CoverageAnnotationTest.java index 89a7e765610..220b208d48d 100644 --- a/src/test/org/openscience/cdk/coverage/CoverageAnnotationTest.java +++ b/src/test/org/openscience/cdk/coverage/CoverageAnnotationTest.java @@ -105,7 +105,7 @@ private int checkClass(String className) { // skip this test } else if (testMethodAnnotation == null) { // if a method does not have the annotation, it's missing a test - System.out.println(className + "#" + method.getName() + " does not have a test method"); + System.out.println(className + "#" + toString(method) + " does not have a test method"); missingTestCount++; } else methodAnnotations.put(method.getName(), testMethodAnnotation); } @@ -172,6 +172,18 @@ private int checkClass(String className) { return missingTestCount; } + private String toString(Method method) { + StringBuffer methodString = new StringBuffer(); + methodString.append(method.getName()).append('('); + Class[] classes = method.getParameterTypes(); + for (int i=0;i