From dee940058d0c579dc9d010f98d39dc836534a918 Mon Sep 17 00:00:00 2001 From: Lars Langhans Date: Tue, 9 Feb 2010 11:18:22 +0100 Subject: [PATCH] qadev40: #161119# refactoring --- qadevOOo/runner/lib/MultiMethodTest.java | 21 +++++++++++++-------- qadevOOo/runner/lib/MultiPropertyTest.java | 3 ++- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/qadevOOo/runner/lib/MultiMethodTest.java b/qadevOOo/runner/lib/MultiMethodTest.java index d6e6833648fb..88a1bb2843c3 100644 --- a/qadevOOo/runner/lib/MultiMethodTest.java +++ b/qadevOOo/runner/lib/MultiMethodTest.java @@ -167,7 +167,8 @@ public class MultiMethodTest if (! entry.entryName.equals("ifc.qadevooo._SelfTest")) { String ifcName = getInterfaceName(); - System.out.println("checking : " + ifcName); + // System.out.println("checking : " + ifcName); + System.out.print("checking: [" + entry.longName + "]"); // defining a name of the class corresponding to the tested interface // or service @@ -186,12 +187,12 @@ public class MultiMethodTest } catch (ClassNotFoundException cnfE) { - + System.out.println(); cnfE.printStackTrace(log); log.println("could not find a class : " + getTestedClassName()); return null; - } + System.out.println(" is iface: [" + testedClassName + "] testcode: [" + entry.entryName + "]"); // quering the tested interface from the tested object XInterface tCase = tEnv.getTestObject(); @@ -234,7 +235,8 @@ public class MultiMethodTest DescEntry aSubEntry = entry.SubEntries[i]; try { - executeMethod(aSubEntry.entryName); + final String sEntryName = aSubEntry.entryName; + executeMethod(sEntryName); } catch (Exception e) { @@ -258,7 +260,7 @@ public class MultiMethodTest * Is called before calling method tests, but after initialization. * Subclasses may override to perform actions before method tests. */ - protected void before() throws Exception + protected void before() { } @@ -321,13 +323,15 @@ public class MultiMethodTest /** * Checks if the method is optional in the service. */ - protected boolean isOptional(String method) + protected boolean isOptional(String _method) { for (int k = 0; k < entry.SubEntryCount; k++) { - if (entry.SubEntries[k].entryName.equals(method)) + final String sName = entry.SubEntries[k].entryName; + if (sName.equals(_method)) { - return entry.SubEntries[k].isOptional; + final boolean bIsOptional = entry.SubEntries[k].isOptional; + return bIsOptional; } } return false; @@ -370,6 +374,7 @@ public class MultiMethodTest log.println("Execute: " + method); callMethod(method); log.println(method + ": " + tRes.getStatusFor(method)); + log.println(); } } diff --git a/qadevOOo/runner/lib/MultiPropertyTest.java b/qadevOOo/runner/lib/MultiPropertyTest.java index cd6f5ce28218..70a1d3d908a6 100644 --- a/qadevOOo/runner/lib/MultiPropertyTest.java +++ b/qadevOOo/runner/lib/MultiPropertyTest.java @@ -158,7 +158,8 @@ public class MultiPropertyTest extends MultiMethodTest if (info != null) { - if (!info.hasPropertyByName(propName)) + final boolean bHasProperty = info.hasPropertyByName(propName); + if (!bHasProperty) { if (isOptional(propName) || optionalService) {