summaryrefslogtreecommitdiff
path: root/qadevOOo
diff options
context:
space:
mode:
Diffstat (limited to 'qadevOOo')
-rw-r--r--qadevOOo/runner/base/basic_fat.java3
-rw-r--r--qadevOOo/runner/base/java_cmp.java5
-rw-r--r--qadevOOo/runner/base/java_fat.java294
-rw-r--r--qadevOOo/runner/base/java_fat_service.java37
-rw-r--r--qadevOOo/runner/basicrunner/basichelper/Filter.java4
-rw-r--r--qadevOOo/runner/complexlib/ComplexTestCase.java100
-rw-r--r--qadevOOo/runner/convwatch/BuildID.java44
-rw-r--r--qadevOOo/runner/convwatch/IniFile.java28
-rw-r--r--qadevOOo/runner/convwatch/OfficePrint.java10
-rw-r--r--qadevOOo/runner/convwatch/PerformanceContainer.java27
-rw-r--r--qadevOOo/runner/convwatch/PixelCounter.java31
-rw-r--r--qadevOOo/runner/graphical/BuildID.java112
-rw-r--r--qadevOOo/runner/graphical/IniFile.java46
-rw-r--r--qadevOOo/runner/graphical/JPEGComparator.java52
-rw-r--r--qadevOOo/runner/graphical/JPEGCreator.java67
-rw-r--r--qadevOOo/runner/graphical/MSOfficePostscriptCreator.java8
-rw-r--r--qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java9
-rw-r--r--qadevOOo/runner/graphical/PostscriptCreator.java70
-rwxr-xr-xqadevOOo/runner/helper/PropertyHelper.java12
-rw-r--r--qadevOOo/runner/lib/MultiMethodTest.java21
-rw-r--r--qadevOOo/runner/lib/MultiPropertyTest.java3
-rw-r--r--qadevOOo/runner/org/openoffice/Runner.java2
-rw-r--r--qadevOOo/runner/stats/Summarizer.java65
-rw-r--r--qadevOOo/tests/java/ifc/io/_XOutputStream.java3
-rw-r--r--qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java11
-rw-r--r--qadevOOo/tests/java/ifc/sdbc/_XWarningsSupplier.java2
-rw-r--r--qadevOOo/tests/java/mod/_acceptor.uno/Acceptor.java3
-rw-r--r--qadevOOo/tests/java/mod/_javaloader.uno/JavaComponentLoader.java1
-rw-r--r--qadevOOo/tests/java/mod/_nestedreg.uno/NestedRegistry.java1
-rw-r--r--qadevOOo/tests/java/mod/_remotebridge.uno/various.java2
-rw-r--r--qadevOOo/tests/java/mod/_streams.uno/MarkableInputStream.java3
-rw-r--r--qadevOOo/tests/java/mod/_streams.uno/MarkableOutputStream.java4
-rw-r--r--qadevOOo/tests/java/mod/_streams.uno/Pipe.java2
33 files changed, 626 insertions, 456 deletions
diff --git a/qadevOOo/runner/base/basic_fat.java b/qadevOOo/runner/base/basic_fat.java
index cfb19d0b1edd..74a6708cf801 100644
--- a/qadevOOo/runner/base/basic_fat.java
+++ b/qadevOOo/runner/base/basic_fat.java
@@ -26,7 +26,6 @@
************************************************************************/
package base;
-import base.TestBase;
import basicrunner.BasicIfcTest;
import basicrunner.BasicTestCase;
@@ -69,7 +68,7 @@ public class basic_fat implements TestBase
/**
* Execute a test.
* @param param The test parameters.
- * @param return True, if the test was executed.
+ * @return True, if the test was executed.
*/
public boolean executeTest(TestParameters param)
{
diff --git a/qadevOOo/runner/base/java_cmp.java b/qadevOOo/runner/base/java_cmp.java
index 1c37b5e16724..c25de6efc4a9 100644
--- a/qadevOOo/runner/base/java_cmp.java
+++ b/qadevOOo/runner/base/java_cmp.java
@@ -28,11 +28,6 @@
package base;
-import com.sun.star.uno.UnoRuntime;
-
-import helper.APIDescGetter;
-import helper.AppProvider;
-import base.TestBase;
/**
diff --git a/qadevOOo/runner/base/java_fat.java b/qadevOOo/runner/base/java_fat.java
index b330e1c597fc..1d75c48ed43e 100644
--- a/qadevOOo/runner/base/java_fat.java
+++ b/qadevOOo/runner/base/java_fat.java
@@ -59,43 +59,43 @@ import util.DynamicClassLoader;
public class java_fat implements TestBase
{
- private static boolean debug = false;
+ private static boolean m_isDebug = false;
private static boolean keepdocument = false;
private static boolean logging = true;
private static boolean newOffice = false;
- private DynamicClassLoader dcl = null;
+ private DynamicClassLoader m_aDynamicClassLoader = null;
private lib.TestParameters m_aParams;
private AppProvider m_aOffice;
- public boolean executeTest(lib.TestParameters param)
+ public boolean executeTest(lib.TestParameters _aParams)
{
- m_aParams = param;
+ m_aParams = _aParams;
- dcl = new DynamicClassLoader();
+ m_aDynamicClassLoader = new DynamicClassLoader();
DescGetter dg = new APIDescGetter();
- String job = (String) param.get("TestJob");
- String ExclusionFile = (String) param.get("ExclusionList");
+ String job = (String) m_aParams.get("TestJob");
+ String ExclusionFile = (String) m_aParams.get("ExclusionList");
Vector exclusions = null;
boolean retValue = true;
- debug = param.getBool("DebugIsActive");
- logging = param.getBool("LoggingIsActive");
- keepdocument = param.getBool("KeepDocument");
- newOffice = param.getBool(util.PropertyName.NEW_OFFICE_INSTANCE);
+ m_isDebug = m_aParams.getBool("DebugIsActive");
+ logging = m_aParams.getBool("LoggingIsActive");
+ keepdocument = m_aParams.getBool("KeepDocument");
+ newOffice = m_aParams.getBool(util.PropertyName.NEW_OFFICE_INSTANCE);
if (keepdocument)
{
System.setProperty("KeepDocument", "true");
}
if (ExclusionFile != null)
{
- exclusions = getExclusionList(ExclusionFile, debug);
+ exclusions = getExclusionList(ExclusionFile, m_isDebug);
}
//get Job-Descriptions
- System.out.println("Getting Descriptions for Job: " + job);
+ // System.out.println("Getting Descriptions for Job: " + job);
- String sDescriptionPath = (String) param.get("DescriptionPath");
- DescEntry[] entries = dg.getDescriptionFor(job, sDescriptionPath, debug);
+ String sDescriptionPath = (String) m_aParams.get("DescriptionPath");
+ DescEntry[] entries = dg.getDescriptionFor(job, sDescriptionPath, m_isDebug);
// System.out.println();
@@ -106,8 +106,8 @@ public class java_fat implements TestBase
return false;
}
-// String officeProviderName = (String) param.get("OfficeProvider");
-// AppProvider office = (AppProvider) dcl.getInstance(officeProviderName);
+// String officeProviderName = (String) m_aParams.get("OfficeProvider");
+// AppProvider office = (AppProvider) m_aDynamicClassLoader.getInstance(officeProviderName);
//
// if (office == null) {
// System.out.println("ERROR: Wrong parameter 'OfficeProvider', " +
@@ -115,18 +115,22 @@ public class java_fat implements TestBase
// System.exit(-1);
// }
- m_aOffice = startOffice(param);
+ m_aOffice = startOffice(m_aParams);
boolean firstRun = true;
+ // Run through all entries (e.g. sw.SwXBookmark.*)
+
for (int l = 0; l < entries.length; l++)
{
- if (entries[l] == null)
+ DescEntry entry = entries[l];
+
+ if (entry == null)
{
continue;
}
- if (entries[l].hasErrorMsg)
+ if (entry.hasErrorMsg)
{
System.out.println(entries[l].ErrorMsg);
retValue = false;
@@ -135,145 +139,86 @@ public class java_fat implements TestBase
if (!firstRun && newOffice)
{
- if (!m_aOffice.closeExistingOffice(param, true))
+ if (!m_aOffice.closeExistingOffice(m_aParams, true))
{
- m_aOffice.disposeManager(param);
+ m_aOffice.disposeManager(m_aParams);
}
- startOffice(param);
+ startOffice(m_aParams);
}
firstRun = false;
-// XMultiServiceFactory msf = (XMultiServiceFactory) office.getManager(
-// param);
-
- XMultiServiceFactory msf = (XMultiServiceFactory) param.getMSF();
+ XMultiServiceFactory msf = (XMultiServiceFactory) m_aParams.getMSF();
if (msf == null)
{
retValue = false;
-
continue;
}
-// param.put("ServiceFactory", msf);
-
- DescEntry entry = entries[l];
-
//get some helper classes
Summarizer sumIt = new Summarizer();
-
- TestCase tCase = null;
-
- try
- {
- tCase = (TestCase) dcl.getInstance("mod._" + entry.entryName);
- }
- catch (java.lang.IllegalArgumentException ie)
- {
- entry.ErrorMsg = ie.getMessage();
- entry.hasErrorMsg = true;
- }
- catch (java.lang.NoClassDefFoundError ie)
- {
- entry.ErrorMsg = ie.getMessage();
- entry.hasErrorMsg = true;
- }
-
+ TestCase tCase = getTestCase(entry);
if (tCase == null)
{
- Summarizer.summarizeDown(entry, entry.ErrorMsg);
-
- LogWriter sumObj = OutProducerFactory.createOutProducer(param);
- entry.UserDefinedParams = param;
- sumObj.initialize(entry, logging);
- sumObj.summary(entry);
-
continue;
}
- if (debug)
- {
- System.out.println("sleeping 5 seconds..");
- }
- util.utils.shortWait(5000);
+// if (m_isDebug)
+// {
+// System.out.println("sleeping 2 seconds..");
+// }
+ util.utils.shortWait(2000);
System.out.println("Creating: " + entry.entryName);
- LogWriter log = (LogWriter) dcl.getInstance((String) param.get("LogWriter"));
+ LogWriter log = (LogWriter) m_aDynamicClassLoader.getInstance((String) m_aParams.get("LogWriter"));
log.initialize(entry, logging);
- entry.UserDefinedParams = param;
-
- TestEnvironment tEnv = null;
+ entry.UserDefinedParams = m_aParams;
- try
- {
- tCase.setLogWriter((PrintWriter) log);
- tCase.initializeTestCase(param);
- tEnv = tCase.getTestEnvironment(param);
- }
- catch (Exception e)
- {
- System.out.println("Exception while creating " + tCase.getObjectName());
- System.out.println("Message " + e.getMessage());
- e.printStackTrace();
- tEnv = null;
- }
- catch (java.lang.UnsatisfiedLinkError e)
- {
- System.out.println("Exception while creating " + tCase.getObjectName());
- System.out.println("Message " + e.getMessage());
- tEnv = null;
- }
- catch (java.lang.NoClassDefFoundError e)
- {
- System.out.println("Exception while creating " + tCase.getObjectName());
- System.out.println("Message " + e.getMessage());
- tEnv = null;
- }
+ tCase.setLogWriter((PrintWriter) log);
+ tCase.initializeTestCase(m_aParams);
+ TestEnvironment tEnv = getTestEnvironment(tCase, entry);
if (tEnv == null)
{
- Summarizer.summarizeDown(entry, "Couldn't create " + tCase.getObjectName());
-
- LogWriter sumObj = OutProducerFactory.createOutProducer(param);
- entry.UserDefinedParams = param;
- sumObj.initialize(entry, logging);
- sumObj.summary(entry);
-
continue;
}
- System.out.println(tCase.getObjectName() + " recreated ");
+ final String sObjectName = tCase.getObjectName();
+ // System.out.println(sObjectName + " recreated ");
for (int j = 0; j < entry.SubEntryCount; j++)
{
DescEntry aSubEntry = entry.SubEntries[j];
- if (!aSubEntry.isToTest)
+ final boolean bIsToTest = aSubEntry.isToTest;
+ if (!bIsToTest)
{
Summarizer.summarizeDown(aSubEntry, "not part of the job");
-
continue;
}
- if ((exclusions != null) && (exclusions.contains(aSubEntry.longName)))
+ // final String sEntryName = aSubEntry.entryName;
+ final String sLongEntryName = aSubEntry.longName;
+
+ if ((exclusions != null) && (exclusions.contains(sLongEntryName)))
{
Summarizer.summarizeDown(aSubEntry, "known issue");
-
continue;
}
- System.out.println("running: '" + aSubEntry.entryName + "'");
+ // System.out.println("running: '" + sLongEntryName + "' testcode: [" + sEntryName + "]");
+ // this will shown in test itself
- LogWriter ifclog = (LogWriter) dcl.getInstance( (String) param.get("LogWriter"));
+ LogWriter ifclog = (LogWriter) m_aDynamicClassLoader.getInstance( (String) m_aParams.get("LogWriter"));
ifclog.initialize(aSubEntry, logging);
- aSubEntry.UserDefinedParams = param;
+ aSubEntry.UserDefinedParams = m_aParams;
aSubEntry.Logger = ifclog;
if ((tEnv == null) || tEnv.isDisposed())
{
closeExistingOffice();
- tEnv = getEnv(entry, param);
+ tEnv = getEnv(entry, m_aParams);
}
// MultiMethodTest ifc = null;
@@ -288,7 +233,7 @@ public class java_fat implements TestBase
{
countInterfaceTestRun++;
finished = true;
- res = executeInterfaceTest(aSubEntry, tEnv, param);
+ res = executeInterfaceTest(aSubEntry, tEnv, m_aParams);
}
catch (IllegalArgumentException iae)
{
@@ -305,7 +250,7 @@ public class java_fat implements TestBase
catch (java.lang.RuntimeException e)
{
closeExistingOffice();
- tEnv = getEnv(entry, param);
+ tEnv = getEnv(entry, m_aParams);
if (countInterfaceTestRun < 2)
{
finished = false;
@@ -320,8 +265,8 @@ public class java_fat implements TestBase
sumIt.summarizeUp(aSubEntry);
- LogWriter sumIfc = OutProducerFactory.createOutProducer(param);
- aSubEntry.UserDefinedParams = param;
+ LogWriter sumIfc = OutProducerFactory.createOutProducer(m_aParams);
+ aSubEntry.UserDefinedParams = m_aParams;
sumIfc.initialize(aSubEntry, logging);
sumIfc.summary(aSubEntry);
}
@@ -330,7 +275,7 @@ public class java_fat implements TestBase
{
if (!keepdocument)
{
- tCase.cleanupTestCase(param);
+ tCase.cleanupTestCase(m_aParams);
}
}
catch (Exception e)
@@ -344,7 +289,7 @@ public class java_fat implements TestBase
sumIt.summarizeUp(entry);
- LogWriter sumObj = OutProducerFactory.createOutProducer(param);
+ LogWriter sumObj = OutProducerFactory.createOutProducer(m_aParams);
sumObj.initialize(entry, logging);
sumObj.summary(entry);
@@ -359,7 +304,8 @@ public class java_fat implements TestBase
for (int i = 0; i < entries.length; i++)
{
- if (!entries[i].State.endsWith("OK"))
+ final String sState = entries[i].State;
+ if (!sState.endsWith("OK"))
{
System.out.println("\t " + entries[i].longName);
counter++;
@@ -373,6 +319,78 @@ public class java_fat implements TestBase
return retValue;
}
+//
+ private TestEnvironment getTestEnvironment(TestCase tCase, DescEntry entry)
+ {
+ TestEnvironment tEnv = null;
+
+ try
+ {
+ tEnv = tCase.getTestEnvironment(m_aParams);
+ }
+ catch (Exception e)
+ {
+ System.out.println("Exception while creating " + tCase.getObjectName());
+ System.out.println("Message " + e.getMessage());
+ e.printStackTrace();
+ tEnv = null;
+ }
+ catch (java.lang.UnsatisfiedLinkError e)
+ {
+ System.out.println("Exception while creating " + tCase.getObjectName());
+ System.out.println("Message " + e.getMessage());
+ tEnv = null;
+ }
+ catch (java.lang.NoClassDefFoundError e)
+ {
+ System.out.println("Exception while creating " + tCase.getObjectName());
+ System.out.println("Message " + e.getMessage());
+ tEnv = null;
+ }
+
+ if (tEnv == null)
+ {
+ Summarizer.summarizeDown(entry, "Couldn't create " + tCase.getObjectName());
+
+ LogWriter sumObj = OutProducerFactory.createOutProducer(m_aParams);
+ entry.UserDefinedParams = m_aParams;
+ sumObj.initialize(entry, logging);
+ sumObj.summary(entry);
+ }
+ return tEnv;
+ }
+ // -------------------------------------------------------------------------
+ private TestCase getTestCase(DescEntry _aEntry)
+ {
+ TestCase tCase = null;
+
+ try
+ {
+ tCase = (TestCase) m_aDynamicClassLoader.getInstance("mod._" + _aEntry.entryName);
+ }
+ catch (java.lang.IllegalArgumentException ie)
+ {
+ _aEntry.ErrorMsg = ie.getMessage();
+ _aEntry.hasErrorMsg = true;
+ }
+ catch (java.lang.NoClassDefFoundError ie)
+ {
+ _aEntry.ErrorMsg = ie.getMessage();
+ _aEntry.hasErrorMsg = true;
+ }
+
+ if (tCase == null)
+ {
+ Summarizer.summarizeDown(_aEntry, _aEntry.ErrorMsg);
+
+ LogWriter sumObj = OutProducerFactory.createOutProducer(m_aParams);
+ _aEntry.UserDefinedParams = m_aParams;
+ sumObj.initialize(_aEntry, logging);
+ sumObj.summary(_aEntry);
+ }
+ return tCase;
+}
+
private void setState(DescEntry aSubEntry, lib.TestResult res)
{
if (res != null)
@@ -390,10 +408,10 @@ public class java_fat implements TestBase
private TestEnvironment getEnv(DescEntry entry, TestParameters param)
{
-// if (dcl == null)
-// dcl = new DynamicClassLoader();
-// String officeProviderName = (String) param.get("OfficeProvider");
-// AppProvider office = (AppProvider) dcl.getInstance(officeProviderName);
+// if (m_aDynamicClassLoader == null)
+// m_aDynamicClassLoader = new DynamicClassLoader();
+// String officeProviderName = (String) m_aParams.get("OfficeProvider");
+// AppProvider office = (AppProvider) m_aDynamicClassLoader.getInstance(officeProviderName);
//
// if (office == null) {
// System.out.println("ERROR: Wrong parameter 'OfficeProvider', " +
@@ -402,21 +420,21 @@ public class java_fat implements TestBase
// }
//
// XMultiServiceFactory msf = (XMultiServiceFactory) office.getManager(
-// param);
+// m_aParams);
//
// if (msf == null) {
// return null;
// }
//
-// param.put("ServiceFactory", msf);
+// m_aParams.put("ServiceFactory", msf);
- // AppProvider office = startOffice(param);
+ // AppProvider office = startOffice(m_aParams);
TestCase tCase = null;
try
{
- tCase = (TestCase) dcl.getInstance("mod._" + entry.entryName);
+ tCase = (TestCase) m_aDynamicClassLoader.getInstance("mod._" + entry.entryName);
}
catch (java.lang.IllegalArgumentException ie)
{
@@ -433,7 +451,7 @@ public class java_fat implements TestBase
entry.UserDefinedParams = param;
- LogWriter log = (LogWriter) dcl.getInstance((String) param.get("LogWriter"));
+ LogWriter log = (LogWriter) m_aDynamicClassLoader.getInstance((String) param.get("LogWriter"));
log.initialize(entry, logging);
tCase.setLogWriter((PrintWriter) log);
@@ -469,21 +487,21 @@ public class java_fat implements TestBase
if (ph != null)
{
m_aOffice.closeExistingOffice(m_aParams, true);
- shortWait(5000);
+ util.utils.shortWait(5000);
}
}
- private void shortWait(int millis)
- {
- try
- {
- Thread.sleep(millis);
- }
- catch (java.lang.InterruptedException ie)
- {
- }
- }
+// private void shortWait(int millis)
+// {
+// try
+// {
+// Thread.sleep(millis);
+// }
+// catch (java.lang.InterruptedException ie)
+// {
+// }
+// }
private Vector getExclusionList(String url, boolean debug)
{
@@ -548,20 +566,20 @@ public class java_fat implements TestBase
DescEntry entry, TestEnvironment tEnv, TestParameters param)
throws IllegalArgumentException, java.lang.NoClassDefFoundError
{
- MultiMethodTest ifc = (MultiMethodTest) dcl.getInstance(entry.entryName);
+ MultiMethodTest ifc = (MultiMethodTest) m_aDynamicClassLoader.getInstance(entry.entryName);
return ifc.run(entry, tEnv, param);
}
private AppProvider startOffice(lib.TestParameters param)
{
- if (dcl == null)
+ if (m_aDynamicClassLoader == null)
{
- dcl = new DynamicClassLoader();
+ m_aDynamicClassLoader = new DynamicClassLoader();
}
String officeProviderName = (String) param.get("OfficeProvider");
- AppProvider office = (AppProvider) dcl.getInstance(officeProviderName);
+ AppProvider office = (AppProvider) m_aDynamicClassLoader.getInstance(officeProviderName);
if (office == null)
{
diff --git a/qadevOOo/runner/base/java_fat_service.java b/qadevOOo/runner/base/java_fat_service.java
index 151a31dadeb0..0c8fd17e43ec 100644
--- a/qadevOOo/runner/base/java_fat_service.java
+++ b/qadevOOo/runner/base/java_fat_service.java
@@ -41,7 +41,6 @@ import com.sun.star.lang.XMultiServiceFactory;
import share.DescEntry;
import share.DescGetter;
import helper.APIDescGetter;
-import base.TestBase;
import share.LogWriter;
import stats.Summarizer;
@@ -174,7 +173,11 @@ public class java_fat_service implements TestBase {
entry.SubEntries[j].entryName);
if ((tEnv != null) && (ifc != null)) {
res = ifc.run(entry.SubEntries[j],tEnv,param);
- } else res = null;
+ }
+ else
+ {
+ res = null;
+ }
}
if (res != null) {
for (int k=0;k<entry.SubEntries[j].SubEntryCount;k++) {
@@ -227,34 +230,38 @@ public class java_fat_service implements TestBase {
TestCase tCase = null;
- try {
- tCase = (TestCase)
- dcl.getInstance("mod._"+entry.entryName);
- } catch (java.lang.IllegalArgumentException ie) {
+ try
+ {
+ tCase = (TestCase) dcl.getInstance("mod._"+entry.entryName);
+ }
+ catch (java.lang.IllegalArgumentException ie)
+ {
entry.ErrorMsg=ie.getMessage();
entry.hasErrorMsg=true;
}
log.println("Creating: "+tCase.getObjectName());
- LogWriter log = (LogWriter)dcl.getInstance(
- (String)param.get("LogWriter"));
+ // LogWriter log = (LogWriter)dcl.getInstance( (String)param.get("LogWriter"));
log.initialize(entry,true);
entry.UserDefinedParams = param;
tCase.setLogWriter((PrintWriter) log);
TestEnvironment tEnv = null;
- try {
+ try
+ {
tCase.initializeTestCase(param);
tEnv = tCase.getTestEnvironment(param);
- } catch (com.sun.star.lang.DisposedException de) {
+ }
+ catch (com.sun.star.lang.DisposedException de)
+ {
log.println("Office disposed");
}
return tEnv;
}
- protected void shortWait(int millis) {
- try {
- Thread.sleep(millis);
- } catch (java.lang.InterruptedException ie) {}
- }
+// protected void shortWait(int millis) {
+// try {
+// Thread.sleep(millis);
+// } catch (java.lang.InterruptedException ie) {}
+// }
}
diff --git a/qadevOOo/runner/basicrunner/basichelper/Filter.java b/qadevOOo/runner/basicrunner/basichelper/Filter.java
index dd45e1fddc81..d9616d30e5b2 100644
--- a/qadevOOo/runner/basicrunner/basichelper/Filter.java
+++ b/qadevOOo/runner/basicrunner/basichelper/Filter.java
@@ -32,7 +32,6 @@ import com.sun.star.lang.XTypeProvider;
import com.sun.star.uno.Type;
import com.sun.star.container.XNameAccess;
import com.sun.star.container.NoSuchElementException;
-import com.sun.star.uno.AnyConverter;
import com.sun.star.uno.UnoRuntime;
import com.sun.star.lang.XSingleServiceFactory;
import com.sun.star.document.XFilter;
@@ -224,7 +223,8 @@ class FilterImpl implements XInitialization, XTypeProvider, XNameAccess {
public void initialize(Object[] parm1) throws com.sun.star.uno.Exception {
XFilter oFilter = (XFilter)UnoRuntime.queryInterface(
XFilter.class, parm1[0]);
- PropertyValue[] FilterDesc = (PropertyValue[])AnyConverter.toArray(parm1[1]);
+//? PropertyValue[] FilterDesc = (PropertyValue[])AnyConverter.toArray(parm1[1]);
+ PropertyValue[] FilterDesc = (PropertyValue[])UnoRuntime.queryInterface(PropertyValue[].class, parm1[1]);
aState = "just initialized";
FilterThread aThread = new FilterThread(oFilter, FilterDesc);
aThread.start();
diff --git a/qadevOOo/runner/complexlib/ComplexTestCase.java b/qadevOOo/runner/complexlib/ComplexTestCase.java
index 8f67cd959f28..b15224bc503f 100644
--- a/qadevOOo/runner/complexlib/ComplexTestCase.java
+++ b/qadevOOo/runner/complexlib/ComplexTestCase.java
@@ -44,8 +44,6 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
protected static TestParameters param = null;
/** Log writer **/
protected static LogWriter log = null;
- /** Description entry **/
- protected DescEntry subEntry = null;
/**
* The method name which will be written into f.e. the data base
**/
@@ -53,42 +51,33 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
/** Maximal time one method is allowed to execute
* Can be set with parameter 'ThreadTimeOut'
**/
- protected int mThreadTimeOut = 0;
+ protected int m_nThreadTimeOut = 0;
/** Continue a test even if it did fail **/
// public static final boolean CONTINUE = true;
/** End a test if it did fail **/
public static final boolean BREAK = true;
+ private boolean m_bBeforeCalled;
+
/**
- * Call test. It is expected, that an environment is
- * given to this test.
- *
- * @param entry The name of the test method that should be called.
- * @param environment The environment for the test.
+ * is called before the real test starts
*/
- public void executeMethods(DescEntry entry, TestParameters environment)
+ private void before()
{
-
- // get the environment
- param = environment;
- log = entry.Logger;
-
- mThreadTimeOut = param.getInt("ThreadTimeOut");
- if (mThreadTimeOut == 0)
- {
- mThreadTimeOut = 300000;
- }
- // start with the before() method
- boolean beforeWorked = true;
try
{
Method before = this.getClass().getMethod("before", new Class[] {} );
before.invoke(this, new Object[] {} );
+
+ // beforeWorked = false;
+ m_bBeforeCalled = true;
}
catch (java.lang.NoSuchMethodException e)
{
// simply ignore
+ int dummy = 0;
+ m_bBeforeCalled = true;
}
catch (java.lang.IllegalAccessException e)
{
@@ -96,7 +85,6 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
}
catch (java.lang.reflect.InvocationTargetException e)
{
- beforeWorked = false;
Throwable t = e.getTargetException();
if (!(t instanceof RuntimeException) || state)
{
@@ -110,12 +98,25 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
}
}
+ }
- //executeMethodTests
- for (int i = 0; i < entry.SubEntries.length; i++)
+ /** Description entry **/
+ // protected DescEntry subEntry = null;
+
+ private void test_method(DescEntry _entry)
+ {
+
+ m_nThreadTimeOut = param.getInt("ThreadTimeOut");
+ if (m_nThreadTimeOut == 0)
{
- subEntry = entry.SubEntries[i];
- if (beforeWorked)
+ m_nThreadTimeOut = 300000;
+ }
+
+ for (int i = 0; i < _entry.SubEntries.length; i++)
+ {
+
+ DescEntry subEntry = _entry.SubEntries[i];
+ if (m_bBeforeCalled)
{
state = true;
message = "";
@@ -138,10 +139,7 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
{
String sParameter = (entryName.substring(entryName.indexOf("(") + 1, entryName.indexOf(")")));
mTestMethodName = entryName;
- parameter = new String[]
- {
- sParameter
- };
+ parameter = new String[] { sParameter };
entryName = entryName.substring(0, entryName.indexOf("("));
testMethod = this.getClass().getMethod(entryName, new Class[] { String.class });
}
@@ -170,7 +168,7 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
int sleepingStep = 1000;
int factor = 0;
- while (th.isAlive() && (lastPing != newPing || factor * sleepingStep < mThreadTimeOut))
+ while (th.isAlive() && (lastPing != newPing || factor * sleepingStep < m_nThreadTimeOut))
{
Thread.sleep(sleepingStep);
factor++;
@@ -193,7 +191,7 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
{
log.println("Destroy " + mTestMethodName);
th.destroy();
- subEntry.State = "Test did sleep for " + (mThreadTimeOut / 1000) + " seconds and has been killed!";
+ subEntry.State = "Test did sleep for " + (m_nThreadTimeOut / 1000) + " seconds and has been killed!";
subEntry.hasErrorMsg = true;
subEntry.ErrorMsg = subEntry.State;
continue;
@@ -225,8 +223,14 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
subEntry.hasErrorMsg = !state;
subEntry.ErrorMsg = message;
}
+ }
- if (beforeWorked)
+ /**
+ * after() is called after the test is done
+ */
+ private void after()
+ {
+ if (m_bBeforeCalled)
{
// the after() method
try
@@ -261,8 +265,38 @@ public abstract class ComplexTestCase extends Assurance implements ComplexTest
}
}
}
+
+ }
+
+
+
+ /**
+ * Call test. It is expected, that an environment is
+ * given to this test.
+ *
+ * @param entry The name of the test method that should be called.
+ * @param environment The environment for the test.
+ */
+ public void executeMethods(DescEntry entry, TestParameters environment)
+ {
+ m_bBeforeCalled = false;
+
+ // get the environment
+ param = environment;
+ log = entry.Logger;
+
+
+ // start with the before() method
+ before();
+
+ //executeMethodTests
+ test_method(entry);
+
+ // cleanup
+ after();
}
+
/**
* Implement this method in the Complex test.
* @return All test method names.
diff --git a/qadevOOo/runner/convwatch/BuildID.java b/qadevOOo/runner/convwatch/BuildID.java
index a1ef08f118f8..efb091d160f9 100644
--- a/qadevOOo/runner/convwatch/BuildID.java
+++ b/qadevOOo/runner/convwatch/BuildID.java
@@ -136,28 +136,28 @@ public class BuildID
}
return sBuildID;
}
- public static void main(String[] args)
- {
- String sApp;
- sApp = "/opt/staroffice8_m116/program/soffice -headless -accept=socket,host=localhost,port=8100;urp;";
- String sBuildID;
- sBuildID = getBuildID(sApp);
- System.out.println("BuildID is: " + sBuildID);
-
- Date aDate = new Date();
- long nStart = aDate.getTime();
- System.out.println("Time:" + nStart);
- // LLA: Just some more tests for getBuildID
- // sApp = "/opt/staroffice8_net/program/soffice";
- // sBuildID = getBuildID(sApp);
- // System.out.println("BuildID is: " + sBuildID);
- //
- // sApp = "\"/opt/staroffice8_net/program/soffice\" test blah";
- // sBuildID = getBuildID(sApp);
- //
- // System.out.println("BuildID is: " + sBuildID);
- System.exit(1);
- }
+// public static void main(String[] args)
+// {
+// String sApp;
+// sApp = "/opt/staroffice8_m116/program/soffice -headless -accept=socket,host=localhost,port=8100;urp;";
+// String sBuildID;
+// sBuildID = getBuildID(sApp);
+// System.out.println("BuildID is: " + sBuildID);
+//
+// Date aDate = new Date();
+// long nStart = aDate.getTime();
+// System.out.println("Time:" + nStart);
+// // LLA: Just some more tests for getBuildID
+// // sApp = "/opt/staroffice8_net/program/soffice";
+// // sBuildID = getBuildID(sApp);
+// // System.out.println("BuildID is: " + sBuildID);
+// //
+// // sApp = "\"/opt/staroffice8_net/program/soffice\" test blah";
+// // sBuildID = getBuildID(sApp);
+// //
+// // System.out.println("BuildID is: " + sBuildID);
+// System.exit(1);
+// }
}
diff --git a/qadevOOo/runner/convwatch/IniFile.java b/qadevOOo/runner/convwatch/IniFile.java
index 27b815e81302..fbcaaea0b33b 100644
--- a/qadevOOo/runner/convwatch/IniFile.java
+++ b/qadevOOo/runner/convwatch/IniFile.java
@@ -435,18 +435,18 @@ class IniFile
/**
* some tests for this class
*/
- public static void main(String[] args)
- {
- IniFile aIniFile = new IniFile("/tmp/inifile");
- String sValue = aIniFile.getValue("Section","Key");
- // insert a new value to a already exist section
- aIniFile.insertValue("Section","Key2","a new value in a existing section");
- // replace a value
- aIniFile.insertValue("Section","Key","replaced value");
- // create a new value
- aIniFile.insertValue("New Section", "Key", "a new key value pair");
-
- String sValue2 = aIniFile.getValue("Section2","Key");
- aIniFile.store();
- }
+// public static void main(String[] args)
+// {
+// IniFile aIniFile = new IniFile("/tmp/inifile");
+// String sValue = aIniFile.getValue("Section","Key");
+// // insert a new value to a already exist section
+// aIniFile.insertValue("Section","Key2","a new value in a existing section");
+// // replace a value
+// aIniFile.insertValue("Section","Key","replaced value");
+// // create a new value
+// aIniFile.insertValue("New Section", "Key", "a new key value pair");
+//
+// String sValue2 = aIniFile.getValue("Section2","Key");
+// aIniFile.store();
+// }
}
diff --git a/qadevOOo/runner/convwatch/OfficePrint.java b/qadevOOo/runner/convwatch/OfficePrint.java
index adf75f093c50..7f9b86f2f920 100644
--- a/qadevOOo/runner/convwatch/OfficePrint.java
+++ b/qadevOOo/runner/convwatch/OfficePrint.java
@@ -108,7 +108,8 @@ public class OfficePrint {
}
catch (com.sun.star.lang.IllegalArgumentException e)
{
- GlobalLogWriter.get().println("showProperty: can't convert a object to string.");
+ // GlobalLogWriter.get().println("showProperty: can't convert a object to string.");
+ GlobalLogWriter.get().println("Property " + sName + ":= a Object which can't convert by AnyConverter()");
}
}
@@ -627,11 +628,12 @@ public class OfficePrint {
{
XPropertySet xPropSet = (XPropertySet) UnoRuntime.queryInterface( XPropertySet.class, aSettings );
xPropSet.setPropertyValue( "PrintAllSheets", new Boolean( true ) );
+ GlobalLogWriter.get().println("PrintAllSheets := true");
}
}
ArrayList aPrintProps = new ArrayList();
- GlobalLogWriter.get().println("Property FileName:=" + _sPrintFileURL);
+ // GlobalLogWriter.get().println("Property FileName:=" + _sPrintFileURL);
// PropertyValue [] aPrintProps = new PropertyValue[nProperties];
PropertyValue Arg = new PropertyValue();
@@ -639,7 +641,7 @@ public class OfficePrint {
Arg.Value = _sPrintFileURL;
// aPrintProps[nPropsCount ++] = Arg;
aPrintProps.add(Arg);
- // showProperty(Arg);
+ showProperty(Arg);
if (_aGTA.printAllPages() == false)
{
@@ -661,8 +663,8 @@ public class OfficePrint {
Arg.Name = "Pages";
Arg.Value = sPages;
aPrintProps.add(Arg);
+ showProperty(Arg);
}
- showProperty(Arg);
// GlobalLogWriter.get().println("Start printing.");
diff --git a/qadevOOo/runner/convwatch/PerformanceContainer.java b/qadevOOo/runner/convwatch/PerformanceContainer.java
index 7a3c39398165..d0c1e0fb5ed1 100644
--- a/qadevOOo/runner/convwatch/PerformanceContainer.java
+++ b/qadevOOo/runner/convwatch/PerformanceContainer.java
@@ -232,18 +232,19 @@ public class PerformanceContainer /* extends *//* implements */ {
}
}
- public static void main(String[] args) {
+// public static void main(String[] args) {
+//
+///*
+// BorderRemover a = new BorderRemover();
+// try
+// {
+// a.createNewImageWithoutBorder(args[0], args[1]);
+// }
+// catch(java.io.IOException e)
+// {
+// System.out.println("Exception caught.");
+// }
+// */
+// }
-/*
- BorderRemover a = new BorderRemover();
- try
- {
- a.createNewImageWithoutBorder(args[0], args[1]);
- }
- catch(java.io.IOException e)
- {
- System.out.println("Exception caught.");
- }
- */
- }
}
diff --git a/qadevOOo/runner/convwatch/PixelCounter.java b/qadevOOo/runner/convwatch/PixelCounter.java
index 3398db89df33..116b07e48d8e 100644
--- a/qadevOOo/runner/convwatch/PixelCounter.java
+++ b/qadevOOo/runner/convwatch/PixelCounter.java
@@ -184,22 +184,23 @@ public class PixelCounter {
// -----------------------------------------------------------------------------
- public static void main(String[] args) {
+// public static void main(String[] args) {
+//
+// String a = helper.StringHelper.createValueString(10, 4);
+// int dummy = 1;
+///*
+// BorderRemover a = new BorderRemover();
+// try
+// {
+// a.createNewImageWithoutBorder(args[0], args[1]);
+// }
+// catch(java.io.IOException e)
+// {
+// System.out.println("Exception caught.");
+// }
+// */
+// }
- String a = helper.StringHelper.createValueString(10, 4);
- int dummy = 1;
-/*
- BorderRemover a = new BorderRemover();
- try
- {
- a.createNewImageWithoutBorder(args[0], args[1]);
- }
- catch(java.io.IOException e)
- {
- System.out.println("Exception caught.");
- }
- */
- }
}
diff --git a/qadevOOo/runner/graphical/BuildID.java b/qadevOOo/runner/graphical/BuildID.java
index a2cbf63cf8cf..4c5907ff34ad 100644
--- a/qadevOOo/runner/graphical/BuildID.java
+++ b/qadevOOo/runner/graphical/BuildID.java
@@ -32,20 +32,23 @@ import helper.OSHelper;
public class BuildID
{
- public static String getBuildID(String _sApp)
+ private static String getOfficePath(String _sApp)
+ {
+ String sOfficePath = "";
+ // TODO: StringHelper.removeQuote?
+ if (_sApp.startsWith("\""))
{
- String sOfficePath = "";
- // TODO: StringHelper.removeQuote?
- if (_sApp.startsWith("\""))
+ int nIdx = _sApp.indexOf("\"", 1);
+ if (nIdx != -1)
{
- int nIdx = _sApp.indexOf("\"", 1);
- if (nIdx != -1)
- {
- // leave double qoute out.
- sOfficePath = _sApp.substring(1, nIdx);
- }
+ // leave double qoute out.
+ sOfficePath = _sApp.substring(1, nIdx);
}
- else
+ }
+ else
+ {
+ // check if _sApp ends with the office executable, if not
+ if (! (_sApp.endsWith("soffice.exe") || _sApp.endsWith("soffice")))
{
// check if a space exist, so we get all until space
int nIdx = _sApp.indexOf(" ", 1);
@@ -58,19 +61,34 @@ public class BuildID
sOfficePath = _sApp.substring(0, nIdx);
}
}
- GlobalLogWriter.get().println("Office path: " + sOfficePath);
+ else
+ {
+ sOfficePath = _sApp;
+ }
+ }
+ // GlobalLogWriter.get().println("Office path: " + sOfficePath);
+ return sOfficePath;
+ }
- // String fs = System.getProperty("file.separator");
+ public static String getBuildID(String _sApp)
+ {
+ final String sOfficePath = getOfficePath(_sApp);
+ final String sBuildID = getBuildID(sOfficePath, "buildid");
+ return sBuildID;
+ }
+
+ private static String getBuildID(String _sOfficePath, String _sIniSection)
+ {
+ File aSOfficeFile = new File(_sOfficePath);
String sBuildID = "";
- File aSOfficeFile = new File(sOfficePath);
if (aSOfficeFile.exists())
{
- sOfficePath = FileHelper.getPath(sOfficePath);
+ String sOfficePath = FileHelper.getPath(_sOfficePath);
// ok. System.out.println("directory: " + sOfficePath);
- sBuildID = getBuildIDFromBootstrap(sOfficePath);
+ sBuildID = getBuildIDFromBootstrap(sOfficePath, _sIniSection);
if (sBuildID.length() == 0)
{
- sBuildID = getBuildIDFromVersion(sOfficePath);
+ sBuildID = getBuildIDFromVersion(sOfficePath, _sIniSection);
}
}
else
@@ -82,7 +100,7 @@ public class BuildID
return sBuildID;
}
- private static String getBuildIDFromBootstrap(String _sOfficePath)
+ private static String getBuildIDFromBootstrap(String _sOfficePath, String _sIniSection)
{
String sBuildID = "";
String sOfficePath;
@@ -97,7 +115,7 @@ public class BuildID
IniFile aIniFile = new IniFile(sOfficePath);
if (aIniFile.is())
{
- sBuildID = aIniFile.getValue("Bootstrap", "buildid");
+ sBuildID = aIniFile.getValue("Bootstrap", /*"buildid"*/ _sIniSection);
}
else
{
@@ -106,7 +124,7 @@ public class BuildID
return sBuildID;
}
- private static String getBuildIDFromVersion(String _sOfficePath)
+ private static String getBuildIDFromVersion(String _sOfficePath, String _sIniSection)
{
// String fs = System.getProperty("file.separator");
String sBuildID = "";
@@ -122,7 +140,7 @@ public class BuildID
IniFile aIniFile = new IniFile(sOfficePath);
if (aIniFile.is())
{
- sBuildID = aIniFile.getValue("Version", "buildid");
+ sBuildID = aIniFile.getValue("Version", /*"buildid"*/ _sIniSection);
}
else
{
@@ -154,5 +172,55 @@ public class BuildID
// System.exit(1);
// }
-}
+ public static String getMaster(String _sOfficePath)
+ {
+ final String sOfficePath = getOfficePath(_sOfficePath);
+ final String sMaster = getBuildID(sOfficePath, "ProductSource");
+ return sMaster;
+ }
+ public static String getMinor(String _sOfficePath)
+ {
+ final String sOfficePath = getOfficePath(_sOfficePath);
+ final String sMinor = "m" + getBuildID(sOfficePath, "ProductMinor");
+ return sMinor;
+ }
+
+ public static String getCWSName(String _sOfficePath)
+ {
+ final String sOfficePath = getOfficePath(_sOfficePath);
+ final String sBuildID = getBuildID(sOfficePath, "buildid");
+ String sCWSName = "MWS";
+ int nIdx = sBuildID.indexOf("[CWS:");
+ if (nIdx > 0)
+ {
+ int nIdx2 = sBuildID.indexOf("]", nIdx);
+ sCWSName = sBuildID.substring(nIdx + 5, nIdx2);
+ }
+ return sCWSName;
+ }
+
+// public static void main(String[] args)
+// {
+// String sApp;
+// sApp = "D:/staroffice9_m63/Sun/StarOffice 9/program/soffice.exe";
+// String sBuildID;
+// sBuildID = getBuildID(sApp);
+// System.out.println("BuildID is: " + sBuildID);
+//
+// String sMaster;
+// sMaster = getMaster(sApp);
+// System.out.println("Master is: " + sMaster);
+//
+// String sMinor;
+// sMinor = getMinor(sApp);
+// System.out.println("Minor is: " + sMinor);
+//
+// String sCWSName;
+// sCWSName = getCWSName(sApp);
+// System.out.println("CWSName is: " + sCWSName);
+//
+// System.exit(1);
+// }
+
+}
diff --git a/qadevOOo/runner/graphical/IniFile.java b/qadevOOo/runner/graphical/IniFile.java
index 5173c493f46a..832aef795e71 100644
--- a/qadevOOo/runner/graphical/IniFile.java
+++ b/qadevOOo/runner/graphical/IniFile.java
@@ -588,29 +588,29 @@ public class IniFile implements Enumeration
/**
* some tests for this class
*/
- public static void main(String[] args)
- {
- String sTempFile = System.getProperty("java.io.tmpdir");
- sTempFile += "inifile";
-
-
- IniFile aIniFile = new IniFile(sTempFile);
- String sValue = aIniFile.getValue("Section", "Key");
- // insert a new value to a already exist section
- aIniFile.insertValue("Section", "Key2", "a new value in a existing section");
- // replace a value
- aIniFile.insertValue("Section", "Key", "replaced value");
- // create a new value
- aIniFile.insertValue("New Section", "Key", "a new key value pair");
- aIniFile.insertValue("New Section", "Key2", "a new second key value pair");
-
- String sValue2 = aIniFile.getValue("Section2", "Key");
-
- aIniFile.removeSection("Section");
- aIniFile.removeSection("New Section");
-
- aIniFile.close();
- }
+// public static void main(String[] args)
+// {
+// String sTempFile = System.getProperty("java.io.tmpdir");
+// sTempFile += "inifile";
+//
+//
+// IniFile aIniFile = new IniFile(sTempFile);
+// String sValue = aIniFile.getValue("Section", "Key");
+// // insert a new value to a already exist section
+// aIniFile.insertValue("Section", "Key2", "a new value in a existing section");
+// // replace a value
+// aIniFile.insertValue("Section", "Key", "replaced value");
+// // create a new value
+// aIniFile.insertValue("New Section", "Key", "a new key value pair");
+// aIniFile.insertValue("New Section", "Key2", "a new second key value pair");
+//
+// String sValue2 = aIniFile.getValue("Section2", "Key");
+//
+// aIniFile.removeSection("Section");
+// aIniFile.removeSection("New Section");
+//
+// aIniFile.close();
+// }
/**
* Enumeration Interface
diff --git a/qadevOOo/runner/graphical/JPEGComparator.java b/qadevOOo/runner/graphical/JPEGComparator.java
index 851d129141ea..ed3417e04c9c 100644
--- a/qadevOOo/runner/graphical/JPEGComparator.java
+++ b/qadevOOo/runner/graphical/JPEGComparator.java
@@ -338,6 +338,8 @@ public class JPEGComparator extends EnhancedComplexTestCase
String sDestination = FileHelper.appendPath(sDestinationPath, sNewSourceBasename);
FileHelper.copy(sSource, sDestination);
sSourceBasename = sNewSourceBasename;
+ //
+ JPEGCreator.convertToNearSameFileWithWidth340(sDestination);
}
String sDifferenceBasename = "Difference_between_" + FileHelper.getNameNoSuffix(sSourceBasename) + "_and_" + FileHelper.getNameNoSuffix(sDestinationBasename) + ".jpg";
// String sDifferencePath = sDestinationPath;
@@ -643,30 +645,30 @@ public class JPEGComparator extends EnhancedComplexTestCase
- public static void main(String [] _args)
- {
-// give an index.ini file, ok
-// give a directory, where exist jpeg files ok
-// inputpath (given file) doesn't exists
-// give a jpeg file.
-
- String args[] = {
- "-TimeOut", "3600000",
- "-tb", "java_complex",
- "-o", "graphical.JPEGComparator",
- "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\index.ini",
- "-DOC_COMPARATOR_OUTPUT_PATH", "C:\\CWS\\temp\\output2",
-// "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\GroupReport.odt.pdf_180DPI_0001.jpg",
-// "-DOC_COMPARATOR_OUTPUT_PATH", "C:\\CWS\\temp\\output2\\Report1.odt.pdf_180DPI_0001.jpg",
- "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX", "http://so-gfxcmp-lin.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
-// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "PDF", /* default: "OOo" */
-// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "msoffice", /* default: "OOo" */
-// "-OFFICE_VIEWABLE", "false",
-// "-AppExecutionCommand", "\"C:/Programme/sun/staroffice 9/program/soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
- "-NoOffice"
- };
-
- org.openoffice.Runner.main(args);
- }
+// public static void main(String [] _args)
+// {
+//// give an index.ini file, ok
+//// give a directory, where exist jpeg files ok
+//// inputpath (given file) doesn't exists
+//// give a jpeg file.
+//
+// String args[] = {
+// "-TimeOut", "3600000",
+// "-tb", "java_complex",
+// "-o", "graphical.JPEGComparator",
+// "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\index.ini",
+// "-DOC_COMPARATOR_OUTPUT_PATH", "C:\\CWS\\temp\\output2",
+//// "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\GroupReport.odt.pdf_180DPI_0001.jpg",
+//// "-DOC_COMPARATOR_OUTPUT_PATH", "C:\\CWS\\temp\\output2\\Report1.odt.pdf_180DPI_0001.jpg",
+// "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX", "http://so-gfxcmp-lin.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
+//// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "PDF", /* default: "OOo" */
+//// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "msoffice", /* default: "OOo" */
+//// "-OFFICE_VIEWABLE", "false",
+//// "-AppExecutionCommand", "\"C:/Programme/sun/staroffice 9/program/soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
+// "-NoOffice"
+// };
+//
+// org.openoffice.Runner.main(args);
+// }
}
diff --git a/qadevOOo/runner/graphical/JPEGCreator.java b/qadevOOo/runner/graphical/JPEGCreator.java
index c35f89b39da8..5f6343d9780d 100644
--- a/qadevOOo/runner/graphical/JPEGCreator.java
+++ b/qadevOOo/runner/graphical/JPEGCreator.java
@@ -124,9 +124,14 @@ public class JPEGCreator extends EnhancedComplexTestCase
*/
public static void convertToNearSameFileWithWidth340(String _sJPEGFilename)
{
+ String sJPEGFilename = _sJPEGFilename.replaceAll("\\\\", "/");
+// if (OSHelper.isWindows())
+// {
+// sJPEGFilename = sJPEGFilename.replaceAll("/", "\\\\");
+// }
String sNewJPEGFilename;
- sNewJPEGFilename = util.utils.replaceAll13(_sJPEGFilename, ".jpg", "_w340.jpg");
- convertToWidth340(_sJPEGFilename, sNewJPEGFilename);
+ sNewJPEGFilename = util.utils.replaceAll13(sJPEGFilename, ".jpg", "_w340.jpg");
+ convertToWidth340(sJPEGFilename, sNewJPEGFilename);
}
/**
@@ -153,7 +158,9 @@ private static void convertToWidth340(String _sFrom, String _To)
}
if (OSHelper.isWindows())
{
- sConvertEXE = "convert.exe";
+ // TODO!
+ // HACK Hard coded!
+ sConvertEXE = "C:\\Programme\\ImageMagick-6.0.3-q8\\convert.exe";
}
String[] sCommandArray =
@@ -378,14 +385,34 @@ private static void convertToWidth340(String _sFrom, String _To)
return nPages;
}
- public static void main(String [] _args)
- {
-// DONE: give an index.ini file ok
+// public static void main(String [] _args)
+// {
+//// DONE: give an index.ini file ok
+//// String args[] = {
+//// "-TimeOut", "3600000",
+//// "-tb", "java_complex",
+//// "-o", "graphical.JPEGCreator",
+//// "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\index.ini",
+//// "-DOC_COMPARATOR_OUTPUT_PATH", "C:\\CWS\\temp\\output",
+//// "-DOC_COMPARATOR_PRINT_MAX_PAGE", "9999",
+//// "-DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION", "180",
+//// "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX", "http://so-gfxcmp-lin.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
+////// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "PDF", /* default: "OOo" */
+////// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "msoffice", /* default: "OOo" */
+////// "-OFFICE_VIEWABLE", "false",
+//// "-AppExecutionCommand", "\"C:/Programme/sun/staroffice 9/program/soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
+//// "-NoOffice"
+//// };
+//
+//// Done: give a directory, where exist pdf/ps files ok.
+//// Done: inputpath (given file) doesn't exists, ok.
+//// Done: give a ps/pdf file. ok.
+//
// String args[] = {
// "-TimeOut", "3600000",
// "-tb", "java_complex",
// "-o", "graphical.JPEGCreator",
-// "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\index.ini",
+// "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\Names7.odt.pdf",
// "-DOC_COMPARATOR_OUTPUT_PATH", "C:\\CWS\\temp\\output",
// "-DOC_COMPARATOR_PRINT_MAX_PAGE", "9999",
// "-DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION", "180",
@@ -396,28 +423,8 @@ private static void convertToWidth340(String _sFrom, String _To)
// "-AppExecutionCommand", "\"C:/Programme/sun/staroffice 9/program/soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
// "-NoOffice"
// };
-
-// Done: give a directory, where exist pdf/ps files ok.
-// Done: inputpath (given file) doesn't exists, ok.
-// Done: give a ps/pdf file. ok.
-
- String args[] = {
- "-TimeOut", "3600000",
- "-tb", "java_complex",
- "-o", "graphical.JPEGCreator",
- "-DOC_COMPARATOR_INPUT_PATH", "C:\\CWS\\temp\\output\\Names7.odt.pdf",
- "-DOC_COMPARATOR_OUTPUT_PATH", "C:\\CWS\\temp\\output",
- "-DOC_COMPARATOR_PRINT_MAX_PAGE", "9999",
- "-DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION", "180",
- "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX", "http://so-gfxcmp-lin.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
-// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "PDF", /* default: "OOo" */
-// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "msoffice", /* default: "OOo" */
-// "-OFFICE_VIEWABLE", "false",
- "-AppExecutionCommand", "\"C:/Programme/sun/staroffice 9/program/soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
- "-NoOffice"
- };
-
- org.openoffice.Runner.main(args);
- }
+//
+// org.openoffice.Runner.main(args);
+// }
}
diff --git a/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java b/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java
index 9c9d7375fd60..8a85c6b32afd 100644
--- a/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java
+++ b/qadevOOo/runner/graphical/MSOfficePostscriptCreator.java
@@ -980,8 +980,8 @@ public class MSOfficePostscriptCreator implements IOffice
return sType;
}
- public static void main(String [] _args)
- {
- String sTest = getXMLDocumentFormat("c:/cws/temp/input/Blah Fasel.xml");
- }
+// public static void main(String [] _args)
+// {
+// String sTest = getXMLDocumentFormat("c:/cws/temp/input/Blah Fasel.xml");
+// }
}
diff --git a/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java b/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java
index 9db2f390a317..06330a06d9ab 100644
--- a/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java
+++ b/qadevOOo/runner/graphical/OpenOfficePostscriptCreator.java
@@ -599,11 +599,12 @@ public class OpenOfficePostscriptCreator implements IOffice
{
XPropertySet xPropSet = (XPropertySet) UnoRuntime.queryInterface( XPropertySet.class, aSettings );
xPropSet.setPropertyValue( "PrintAllSheets", new Boolean( true ) );
+ GlobalLogWriter.get().println("PrintAllSheets := true");
}
}
ArrayList aPrintProps = new ArrayList();
- GlobalLogWriter.get().println("Property FileName:=" + _sPrintFileURL);
+ // GlobalLogWriter.get().println("Property FileName:=" + _sPrintFileURL);
// PropertyValue [] aPrintProps = new PropertyValue[nProperties];
PropertyValue Arg = new PropertyValue();
@@ -611,7 +612,7 @@ public class OpenOfficePostscriptCreator implements IOffice
Arg.Value = _sPrintFileURL;
// aPrintProps[nPropsCount ++] = Arg;
aPrintProps.add(Arg);
- // showProperty(Arg);
+ showProperty(Arg);
// generate pages string
@@ -635,8 +636,8 @@ public class OpenOfficePostscriptCreator implements IOffice
Arg.Name = "Pages";
Arg.Value = sPages;
aPrintProps.add(Arg);
+ showProperty(Arg);
}
- showProperty(Arg);
// GlobalLogWriter.get().println("Start printing.");
@@ -666,6 +667,8 @@ public class OpenOfficePostscriptCreator implements IOffice
throw new com.sun.star.uno.Exception("Convwatch exception, wait too long for printing.");
}
}
+ // TimeHelper.waitInSeconds(40, "Start waiting after print ready.");
+
_aGTA.getPerformance().stopTime(PerformanceContainer.Print);
GlobalLogWriter.get().println(DateHelper.getDateTimeForHumanreadableLog() + " Print document done.");
diff --git a/qadevOOo/runner/graphical/PostscriptCreator.java b/qadevOOo/runner/graphical/PostscriptCreator.java
index f67977115bcd..ab7ad4536fa6 100644
--- a/qadevOOo/runner/graphical/PostscriptCreator.java
+++ b/qadevOOo/runner/graphical/PostscriptCreator.java
@@ -98,40 +98,40 @@ public class PostscriptCreator extends EnhancedComplexTestCase
- public static void main(String [] _args)
- {
- String args[] = {
- "-TimeOut", "3600000",
- "-tb", "java_complex",
- "-o", "graphical.PostscriptCreator",
-// "-DOC_COMPARATOR_INPUT_PATH", "D:\\temp\\input",
-// "-DOC_COMPARATOR_OUTPUT_PATH", "D:\\temp\\output",
-// "-DOC_COMPARATOR_REFERENCE_PATH", "D:\\temp\\output\\ref",
-// "-DOC_COMPARATOR_PRINT_MAX_PAGE", "9999",
-// "-DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION", "180",
-// "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX", "http://so-gfxcmp-lin.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
-//// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "PDF", /* default: "OOo" */
-//// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "msoffice", /* default: "OOo" */
-//// "-OFFICE_VIEWABLE", "false",
-// "-AppExecutionCommand", "\"C:/home/ll93751/staroffice9_DEV300_m25/Sun/StarOffice 9/program/soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
-//// "-NoOffice"
- "-DOC_COMPARATOR_PRINT_MAX_PAGE","9999",
- "-DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION","180",
- "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX","http://so-gfxcmp.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
- "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE","OOo",
- "-DOC_COMPARATOR_DB_INFO_STRING","p:DEV300_m18,c:,d:LLA_test,src:DEV300_m18,dest:,doc:LLA_test,id:34715,distinct:2008-06-27_13-39-09_d6f22d4c-958d-10",
- "-DISTINCT","2008-06-27_13-39-09_d6f22d4c-958d-10",
- "-TEMPPATH","//so-gfxcmp-lin/gfxcmp-data/wntmsci/temp/2008-06-27_13-39-09_d6f22d4c-958d-10/34715",
-// "ConnectionString","socket,host=localhost,port=8101",
- "-OFFICE_VIEWABLE","true",
- "-wntmsci.DOC_COMPARATOR_INPUT_PATH","\\\\so-gfxcmp-lin\\doc-pool\\LLA_test\\issue_79214.odb",
- "-wntmsci.DOC_COMPARATOR_OUTPUT_PATH","\\\\so-gfxcmp-lin\\gfxcmp-data\\wntmsci\\convwatch-output\\LLA_test\\DEV300_m11",
- "-wntmsci.AppExecutionCommand","\"C:\\gfxcmp\\programs\\staroffice8_DEV300_m11\\Sun\\StarOffice 9\\program\\soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
- "-wntmsci.AppKillCommand","\"C:\\bin\\pskill.exe soffice.bin;C:\\bin\\pskill.exe winword;C:\\bin\\pskill.exe excel\"",
-
- };
-
- org.openoffice.Runner.main(args);
- }
+// public static void main(String [] _args)
+// {
+// String args[] = {
+// "-TimeOut", "3600000",
+// "-tb", "java_complex",
+// "-o", "graphical.PostscriptCreator",
+//// "-DOC_COMPARATOR_INPUT_PATH", "D:\\temp\\input",
+//// "-DOC_COMPARATOR_OUTPUT_PATH", "D:\\temp\\output",
+//// "-DOC_COMPARATOR_REFERENCE_PATH", "D:\\temp\\output\\ref",
+//// "-DOC_COMPARATOR_PRINT_MAX_PAGE", "9999",
+//// "-DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION", "180",
+//// "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX", "http://so-gfxcmp-lin.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
+////// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "PDF", /* default: "OOo" */
+////// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE", "msoffice", /* default: "OOo" */
+////// "-OFFICE_VIEWABLE", "false",
+//// "-AppExecutionCommand", "\"C:/home/ll93751/staroffice9_DEV300_m25/Sun/StarOffice 9/program/soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
+////// "-NoOffice"
+// "-DOC_COMPARATOR_PRINT_MAX_PAGE","9999",
+// "-DOC_COMPARATOR_GFX_OUTPUT_DPI_RESOLUTION","180",
+// "-DOC_COMPARATOR_HTML_OUTPUT_PREFIX","http://so-gfxcmp.germany.sun.com/gfxcmp_ui/cw.php?inifile=",
+// "-DOC_COMPARATOR_REFERENCE_CREATOR_TYPE","OOo",
+// "-DOC_COMPARATOR_DB_INFO_STRING","p:DEV300_m18,c:,d:LLA_test,src:DEV300_m18,dest:,doc:LLA_test,id:34715,distinct:2008-06-27_13-39-09_d6f22d4c-958d-10",
+// "-DISTINCT","2008-06-27_13-39-09_d6f22d4c-958d-10",
+// "-TEMPPATH","//so-gfxcmp-lin/gfxcmp-data/wntmsci/temp/2008-06-27_13-39-09_d6f22d4c-958d-10/34715",
+//// "ConnectionString","socket,host=localhost,port=8101",
+// "-OFFICE_VIEWABLE","true",
+// "-wntmsci.DOC_COMPARATOR_INPUT_PATH","\\\\so-gfxcmp-lin\\doc-pool\\LLA_test\\issue_79214.odb",
+// "-wntmsci.DOC_COMPARATOR_OUTPUT_PATH","\\\\so-gfxcmp-lin\\gfxcmp-data\\wntmsci\\convwatch-output\\LLA_test\\DEV300_m11",
+// "-wntmsci.AppExecutionCommand","\"C:\\gfxcmp\\programs\\staroffice8_DEV300_m11\\Sun\\StarOffice 9\\program\\soffice.exe\" -norestore -nocrashreport -accept=pipe,name=ll93751;urp;",
+// "-wntmsci.AppKillCommand","\"C:\\bin\\pskill.exe soffice.bin;C:\\bin\\pskill.exe winword;C:\\bin\\pskill.exe excel\"",
+//
+// };
+//
+// org.openoffice.Runner.main(args);
+// }
}
diff --git a/qadevOOo/runner/helper/PropertyHelper.java b/qadevOOo/runner/helper/PropertyHelper.java
index a517f6c0ae41..1b2bdbb9f175 100755
--- a/qadevOOo/runner/helper/PropertyHelper.java
+++ b/qadevOOo/runner/helper/PropertyHelper.java
@@ -63,6 +63,18 @@ public class PropertyHelper
// {
// aSaveProperties = new PropertyValue[0];
// }
+
+// show properties?
+// if (_aPropertyList.size() > 0)
+// {
+// // aSaveProperties = new PropertyValue[_aPropertyList.size()];
+// for (int i = 0;i<_aPropertyList.size(); i++)
+// {
+// PropertyValue aProp = (PropertyValue) _aPropertyList.get(i);
+// showProperty(aProp);
+// }
+// }
+
}
return aSaveProperties;
}
diff --git a/qadevOOo/runner/lib/MultiMethodTest.java b/qadevOOo/runner/lib/MultiMethodTest.java
index 5a64357401f6..884059bcfd88 100644
--- a/qadevOOo/runner/lib/MultiMethodTest.java
+++ b/qadevOOo/runner/lib/MultiMethodTest.java
@@ -164,7 +164,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
@@ -183,12 +184,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();
@@ -231,7 +232,8 @@ public class MultiMethodTest
DescEntry aSubEntry = entry.SubEntries[i];
try
{
- executeMethod(aSubEntry.entryName);
+ final String sEntryName = aSubEntry.entryName;
+ executeMethod(sEntryName);
}
catch (Exception e)
{
@@ -255,7 +257,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()
{
}
@@ -318,13 +320,15 @@ public class MultiMethodTest
/**
* Checks if the <code>method</code> 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;
@@ -367,6 +371,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 f4973eb94251..286ddf1600a9 100644
--- a/qadevOOo/runner/lib/MultiPropertyTest.java
+++ b/qadevOOo/runner/lib/MultiPropertyTest.java
@@ -155,7 +155,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)
{
diff --git a/qadevOOo/runner/org/openoffice/Runner.java b/qadevOOo/runner/org/openoffice/Runner.java
index 993f18018c4b..979fc527f775 100644
--- a/qadevOOo/runner/org/openoffice/Runner.java
+++ b/qadevOOo/runner/org/openoffice/Runner.java
@@ -184,7 +184,7 @@ public class Runner
public static void main(String[] args)
{
- System.out.println("OOoRunner Main() version from 20090825 (yyyymmdd)");
+ System.out.println("OOoRunner Main() version from 20100125 (yyyymmdd)");
setStartTime(getTime());
diff --git a/qadevOOo/runner/stats/Summarizer.java b/qadevOOo/runner/stats/Summarizer.java
index eaa44a432361..b1fe5fe61dd3 100644
--- a/qadevOOo/runner/stats/Summarizer.java
+++ b/qadevOOo/runner/stats/Summarizer.java
@@ -24,7 +24,6 @@
* for a copy of the LGPLv3 License.
*
************************************************************************/
-
package stats;
import java.util.Vector;
@@ -35,57 +34,81 @@ import share.DescEntry;
* this class summs up the results of the subentries of a given DescEntry<br>
* and fills the subentries in cases of SKIPPED states
*/
-public class Summarizer {
+public class Summarizer
+{
/**
*
* gets the state for a SuperEntry according to its subentries
* @param entry
*/
- public void summarizeUp(DescEntry entry) {
- if ( ( entry.State != null ) && !entry.State.equals("UNKNOWN")) return;
+ public void summarizeUp(DescEntry entry)
+ {
+ if ((entry.State != null) && !entry.State.equals("UNKNOWN"))
+ {
+ return;
+ }
int count = entry.SubEntryCount;
int knownIssues = 0;
Vector failures = new Vector();
Vector states = new Vector();
- for (int i=0; i<count; i++) {
- if (entry.SubEntries[i].State == null) {
+ for (int i = 0; i < count; i++)
+ {
+ if (entry.SubEntries[i].State == null)
+ {
entry.SubEntries[i].State = "PASSED.FAILED";
}
- if (entry.SubEntries[i].State.equals("known issue")) {
+ if (entry.SubEntries[i].State.equals("known issue"))
+ {
entry.SubEntries[i].State = "PASSED.OK";
knownIssues++;
}
- if (!entry.SubEntries[i].State.endsWith("OK")) {
- failures.add(entry.SubEntries[i].entryName);
+ if (!entry.SubEntries[i].State.endsWith("OK"))
+ {
+ String sFailure = "[" + entry.SubEntries[i].longName + "]" + " is testcode: [" + entry.SubEntries[i].entryName + "]";
+ failures.add(sFailure);
states.add(entry.SubEntries[i].State);
}
}
- if (failures.size()>0) {
+ if (failures.size() > 0)
+ {
String errMsg = "";
String state = "PASSED.FAILED";
- for (int j=0; j<failures.size();j++) {
- if (states.elementAt(j).equals("not part of the job")) {
+ for (int j = 0; j < failures.size(); j++)
+ {
+ if (states.elementAt(j).equals("not part of the job"))
+ {
state = "Not possible since not all Interfaces/Services have been checked";
- } else errMsg +=
- failures.elementAt(j)+" - "+states.elementAt(j)+"\r\n";
+ }
+ else
+ {
+ errMsg +=
+ failures.elementAt(j) + " - " + states.elementAt(j) + "\r\n";
+ }
}
- entry.hasErrorMsg=true;
+ entry.hasErrorMsg = true;
entry.ErrorMsg = errMsg;
entry.State = state;
- } else if (entry.EntryType.equals("component") && knownIssues > 0) {
+ }
+ else if (entry.EntryType.equals("component") && knownIssues > 0)
+ {
entry.State = "PASSED(with known issues).OK";
- } else {
+ }
+ else
+ {
entry.State = "PASSED.OK";
}
}
- public static void summarizeDown(DescEntry entry, String state) {
- if ( ( entry.State == null ) || entry.State.equals("UNKNOWN"))
+ public static void summarizeDown(DescEntry entry, String state)
+ {
+ if ((entry.State == null) || entry.State.equals("UNKNOWN"))
+ {
entry.State = state;
- for (int i=0; i<entry.SubEntryCount; i++) {
+ }
+ for (int i = 0; i < entry.SubEntryCount; i++)
+ {
summarizeDown(entry.SubEntries[i], entry.State);
}
}
-
}
diff --git a/qadevOOo/tests/java/ifc/io/_XOutputStream.java b/qadevOOo/tests/java/ifc/io/_XOutputStream.java
index 3f5b00fde4e7..c49aa479ee38 100644
--- a/qadevOOo/tests/java/ifc/io/_XOutputStream.java
+++ b/qadevOOo/tests/java/ifc/io/_XOutputStream.java
@@ -93,9 +93,8 @@ public class _XOutputStream extends MultiMethodTest {
XInputStream xInStream = checker.getInStream();
byte[][] readData = new byte[1][data.length];
- int iReadBytes = 0;
try {
- iReadBytes = xInStream.readBytes(readData, data.length);
+ xInStream.readBytes(readData, data.length);
} catch(com.sun.star.io.IOException e) {
log.println("Couldn't read data:" + e);
res = false;
diff --git a/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java b/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java
index 08d77ccc0ee3..b11659265441 100644
--- a/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java
+++ b/qadevOOo/tests/java/ifc/sdb/_XSingleSelectQueryComposer.java
@@ -78,7 +78,7 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
* @see om.sun.star.sdb.XSingleSelectQueryAnalyzer
* @see com.sun.star.beans.XPropertySet
*/
- protected void before() throws Exception {
+ protected void before() /* throws Exception*/ {
xQueryAna = (XSingleSelectQueryAnalyzer)
UnoRuntime.queryInterface(XSingleSelectQueryAnalyzer.class,
@@ -100,7 +100,14 @@ public class _XSingleSelectQueryComposer extends MultiMethodTest {
}
- colName = AnyConverter.toString(tEnv.getObjRelation("colName"));
+ try
+ {
+ colName = AnyConverter.toString(tEnv.getObjRelation("colName"));
+ }
+ catch (com.sun.star.lang.IllegalArgumentException e)
+ {
+ colName = null;
+ }
if (colName == null) {
throw new StatusException(Status.failed(
diff --git a/qadevOOo/tests/java/ifc/sdbc/_XWarningsSupplier.java b/qadevOOo/tests/java/ifc/sdbc/_XWarningsSupplier.java
index 014152d79193..cbca4c600a4a 100644
--- a/qadevOOo/tests/java/ifc/sdbc/_XWarningsSupplier.java
+++ b/qadevOOo/tests/java/ifc/sdbc/_XWarningsSupplier.java
@@ -136,4 +136,4 @@ public class _XWarningsSupplier extends MultiMethodTest {
tRes.tested("clearWarnings()", res);
}
-} \ No newline at end of file
+}
diff --git a/qadevOOo/tests/java/mod/_acceptor.uno/Acceptor.java b/qadevOOo/tests/java/mod/_acceptor.uno/Acceptor.java
index 7ae71682bb91..64ce14d88417 100644
--- a/qadevOOo/tests/java/mod/_acceptor.uno/Acceptor.java
+++ b/qadevOOo/tests/java/mod/_acceptor.uno/Acceptor.java
@@ -45,9 +45,6 @@ import util.utils;
* @see ifc.connection._XAcceptor
*/
public class Acceptor extends TestCase {
-
- private XInterface acceptor = null ;
-
/**
* Acceptor chooses the first port after <code>basePort</code>
* which is free.
diff --git a/qadevOOo/tests/java/mod/_javaloader.uno/JavaComponentLoader.java b/qadevOOo/tests/java/mod/_javaloader.uno/JavaComponentLoader.java
index de082c380da5..7e9a5f68f5a7 100644
--- a/qadevOOo/tests/java/mod/_javaloader.uno/JavaComponentLoader.java
+++ b/qadevOOo/tests/java/mod/_javaloader.uno/JavaComponentLoader.java
@@ -84,7 +84,6 @@ public class JavaComponentLoader extends TestCase {
tEnv.addObjRelation("ImplementationLoader",
"com.sun.star.loader.JavaComponentLoader") ;
- String jarname = "MyPersistentObjectImpl.jar";
String implURL = utils.getFullTestURL("qadevlibs/MyPersistObjectImpl.jar");
tEnv.addObjRelation("ImplementationUrl", implURL) ;
log.println("looking for shared lib: " + implURL);
diff --git a/qadevOOo/tests/java/mod/_nestedreg.uno/NestedRegistry.java b/qadevOOo/tests/java/mod/_nestedreg.uno/NestedRegistry.java
index 7bb057435f82..6c5f7dc53997 100644
--- a/qadevOOo/tests/java/mod/_nestedreg.uno/NestedRegistry.java
+++ b/qadevOOo/tests/java/mod/_nestedreg.uno/NestedRegistry.java
@@ -136,7 +136,6 @@ public class NestedRegistry extends TestCase {
protected TestEnvironment createTestEnvironment(TestParameters Param, PrintWriter log) {
XInterface oObj = null;
Object oInterface = null;
- Object fileAcc = null;
final String tmpDir = utils.getOfficeTempDirSys(
(XMultiServiceFactory)Param.getMSF()) ;
diff --git a/qadevOOo/tests/java/mod/_remotebridge.uno/various.java b/qadevOOo/tests/java/mod/_remotebridge.uno/various.java
index 76f5cab28e85..0bcaecc361db 100644
--- a/qadevOOo/tests/java/mod/_remotebridge.uno/various.java
+++ b/qadevOOo/tests/java/mod/_remotebridge.uno/various.java
@@ -160,7 +160,7 @@ public class various extends TestCase {
public void run() {
try {
acceptedCall = acc.accept(connectString) ;
- XBridge xBridge = xBrdgFctr.createBridge("MyBridge", "urp",
+ xBrdgFctr.createBridge("MyBridge", "urp",
acceptedCall, xInstProv);
} catch (com.sun.star.lang.IllegalArgumentException e) {
ex = e ;
diff --git a/qadevOOo/tests/java/mod/_streams.uno/MarkableInputStream.java b/qadevOOo/tests/java/mod/_streams.uno/MarkableInputStream.java
index ad16c00bc7a2..a7bcb00a2087 100644
--- a/qadevOOo/tests/java/mod/_streams.uno/MarkableInputStream.java
+++ b/qadevOOo/tests/java/mod/_streams.uno/MarkableInputStream.java
@@ -110,9 +110,6 @@ public class MarkableInputStream extends TestCase {
XActiveDataSource xdSmo = (XActiveDataSource)
UnoRuntime.queryInterface(XActiveDataSource.class, mostream);
- XOutputStream moStream = (XOutputStream)
- UnoRuntime.queryInterface(XOutputStream.class, mostream);
-
XOutputStream PipeOut = (XOutputStream)
UnoRuntime.queryInterface(XOutputStream.class, aPipe);
XInputStream PipeIn = (XInputStream)
diff --git a/qadevOOo/tests/java/mod/_streams.uno/MarkableOutputStream.java b/qadevOOo/tests/java/mod/_streams.uno/MarkableOutputStream.java
index 5f9aeac2a598..d7bfd8efbb96 100644
--- a/qadevOOo/tests/java/mod/_streams.uno/MarkableOutputStream.java
+++ b/qadevOOo/tests/java/mod/_streams.uno/MarkableOutputStream.java
@@ -96,10 +96,6 @@ public class MarkableOutputStream extends TestCase {
protected TestEnvironment createTestEnvironment(TestParameters Param, PrintWriter log) {
XInterface oObj = null;
- Object ostream = null;
-
- Object istream = null ;
- XOutputStream moStream = null ;
XMultiServiceFactory xMSF = (XMultiServiceFactory)Param.getMSF();
Object aPipe = null;
diff --git a/qadevOOo/tests/java/mod/_streams.uno/Pipe.java b/qadevOOo/tests/java/mod/_streams.uno/Pipe.java
index d501febc0017..440550a5b444 100644
--- a/qadevOOo/tests/java/mod/_streams.uno/Pipe.java
+++ b/qadevOOo/tests/java/mod/_streams.uno/Pipe.java
@@ -88,7 +88,6 @@ public class Pipe extends TestCase {
TestEnvironment tEnv = new TestEnvironment( oObj );
//add relation for io.XOutputStream
- final XMultiServiceFactory msf = (XMultiServiceFactory)Param.getMSF();
final XInputStream iStream = (XInputStream)
UnoRuntime.queryInterface(XInputStream.class, oObj);
@@ -97,7 +96,6 @@ public class Pipe extends TestCase {
tEnv.addObjRelation("XOutputStream.StreamChecker",
new ifc.io._XOutputStream.StreamChecker() {
- XInputStream inStream = null;
public void resetStreams() {
}