diff options
Diffstat (limited to 'sc/qa/complex/dataPilot')
-rw-r--r-- | sc/qa/complex/dataPilot/CheckDataPilot.java | 198 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/_XDataPilotDescriptor.java (renamed from sc/qa/complex/dataPilot/interfaceTests/sheet/_XDataPilotDescriptor.java) | 135 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/_XDataPilotTable.java (renamed from sc/qa/complex/dataPilot/interfaceTests/sheet/_XDataPilotTable.java) | 26 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/_XNamed.java (renamed from sc/qa/complex/dataPilot/interfaceTests/container/_XNamed.java) | 46 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/_XPropertySet.java (renamed from sc/qa/complex/dataPilot/interfaceTests/beans/_XPropertySet.java) | 164 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/interfaceTests/beans/makefile.mk | 6 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/interfaceTests/container/makefile.mk | 6 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/interfaceTests/sheet/makefile.mk | 6 | ||||
-rw-r--r-- | sc/qa/complex/dataPilot/makefile.mk | 45 |
9 files changed, 368 insertions, 264 deletions
diff --git a/sc/qa/complex/dataPilot/CheckDataPilot.java b/sc/qa/complex/dataPilot/CheckDataPilot.java index d013daa24e1f..b042f259072e 100644 --- a/sc/qa/complex/dataPilot/CheckDataPilot.java +++ b/sc/qa/complex/dataPilot/CheckDataPilot.java @@ -31,12 +31,12 @@ import com.sun.star.beans.XPropertySet; import com.sun.star.container.XIndexAccess; import com.sun.star.container.XNamed; import com.sun.star.lang.XMultiServiceFactory; -import com.sun.star.sheet.TableFilterField; +// import com.sun.star.sheet.TableFilterField; import com.sun.star.sheet.XDataPilotDescriptor; import com.sun.star.sheet.XDataPilotTable; import com.sun.star.sheet.XDataPilotTables; import com.sun.star.sheet.XDataPilotTablesSupplier; -import com.sun.star.sheet.XSheetFilterDescriptor; +// import com.sun.star.sheet.XSheetFilterDescriptor; import com.sun.star.sheet.XSpreadsheet; import com.sun.star.sheet.XSpreadsheetDocument; import com.sun.star.sheet.XSpreadsheets; @@ -46,29 +46,47 @@ import com.sun.star.uno.AnyConverter; import com.sun.star.uno.Type; import com.sun.star.uno.UnoRuntime; import com.sun.star.uno.XInterface; -import complex.dataPilot.interfaceTests.beans._XPropertySet; -import complex.dataPilot.interfaceTests.container._XNamed; -import complex.dataPilot.interfaceTests.sheet._XDataPilotDescriptor; -import complex.dataPilot.interfaceTests.sheet._XDataPilotTable; -import complexlib.ComplexTestCase; +import com.sun.star.util.XCloseable; +import complex.dataPilot._XPropertySet; +import complex.dataPilot._XNamed; +import complex.dataPilot._XDataPilotDescriptor; +import complex.dataPilot._XDataPilotTable; +// import complexlib.ComplexTestCase; import lib.StatusException; +import lib.TestParameters; import util.SOfficeFactory; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; +import org.openoffice.test.OfficeConnection; +import static org.junit.Assert.*; + + /** * check the DataPilot of Calc. */ -public class CheckDataPilot extends ComplexTestCase { +public class CheckDataPilot { /** The data pilot field object **/ private XInterface mDataPilotFieldObject = null; /** The data pilot table object **/ private XInterface mDataPilotTableObject = null; + + private XSpreadsheetDocument xSheetDoc = null; + /** * A field is filled some values. This integer determines the size of the * field in x and y direction. */ private int mMaxFieldIndex = 6; + /** + * The test parameters + */ + private static TestParameters param = null; /** * Get all test methods @@ -83,27 +101,27 @@ public class CheckDataPilot extends ComplexTestCase { * Test the data pilot field object: * simply execute the interface tests in a row */ - public void testDataPilotFieldObject() { - log.println("Starting 'testDataPilotFieldObject'"); + @Test public void testDataPilotFieldObject() { + System.out.println("Starting 'testDataPilotFieldObject'"); // _XNamed - XNamed xNamed = (XNamed)UnoRuntime.queryInterface( + XNamed xNamed = UnoRuntime.queryInterface( XNamed.class, mDataPilotFieldObject); - _XNamed _xNamed = new _XNamed(xNamed, log, param); - assure("_getName failed.",_xNamed._getName()); - assure("_setName failed.",_xNamed._setName()); + _XNamed _xNamed = new _XNamed(xNamed/*, log*/, param); + assertTrue("_getName failed.",_xNamed._getName()); + assertTrue("_setName failed.",_xNamed._setName()); // _XPropertySet - XPropertySet xProp = (XPropertySet)UnoRuntime.queryInterface( + XPropertySet xProp = UnoRuntime.queryInterface( XPropertySet.class, mDataPilotFieldObject); - _XPropertySet _xProp = new _XPropertySet(xProp, log, param); - assure("_getPropertySetInfo failed.",_xProp._getPropertySetInfo()); - assure("_addPropertyChangeListener failed.",_xProp._addPropertyChangeListener()); - assure("_addVetoableChangeListener failed.",_xProp._addVetoableChangeListener()); - assure("_setPropertyValue failed.",_xProp._setPropertyValue()); - assure("_getPropertyValue failed.",_xProp._getPropertyValue()); - assure("_removePropertyChangeListener failed.",_xProp._removePropertyChangeListener()); - assure("_removeVetoableChangeListener failed.",_xProp._removeVetoableChangeListener()); + _XPropertySet _xProp = new _XPropertySet(xProp/*, log*/, param); + assertTrue("_getPropertySetInfo failed.",_xProp._getPropertySetInfo()); + assertTrue("_addPropertyChangeListener failed.",_xProp._addPropertyChangeListener()); + assertTrue("_addVetoableChangeListener failed.",_xProp._addVetoableChangeListener()); + assertTrue("_setPropertyValue failed.",_xProp._setPropertyValue()); + assertTrue("_getPropertyValue failed.",_xProp._getPropertyValue()); + assertTrue("_removePropertyChangeListener failed.",_xProp._removePropertyChangeListener()); + assertTrue("_removeVetoableChangeListener failed.",_xProp._removeVetoableChangeListener()); } @@ -111,53 +129,57 @@ public class CheckDataPilot extends ComplexTestCase { * Test the data pilot table object: * simply execute the interface tests in a row */ - public void testDataPilotTableObject() { - log.println("Starting 'testDataPilotTableObject'"); + @Test public void testDataPilotTableObject() { + System.out.println("Starting 'testDataPilotTableObject'"); // _XNamed - XNamed xNamed = (XNamed)UnoRuntime.queryInterface( + XNamed xNamed = UnoRuntime.queryInterface( XNamed.class, mDataPilotTableObject); - _XNamed _xNamed = new _XNamed(xNamed, log, param); - assure("_getName failed.",_xNamed._getName()); - assure("_setName failed.",_xNamed._setName()); + _XNamed _xNamed = new _XNamed(xNamed/*, log*/, param); + assertTrue("_getName failed.",_xNamed._getName()); + assertTrue("_setName failed.",_xNamed._setName()); // _XDataPilotTable - XDataPilotTable xDataPilotTable = (XDataPilotTable) + XDataPilotTable xDataPilotTable = UnoRuntime.queryInterface(XDataPilotTable.class, mDataPilotTableObject); _XDataPilotTable _xDataPilotTable = - new _XDataPilotTable(xDataPilotTable, log, param); - assure("before failed.", _xDataPilotTable.before()); - assure("_getOutputRange failed.", _xDataPilotTable._getOutputRange()) ; - assure("_refresh failed.", _xDataPilotTable._refresh()) ; + new _XDataPilotTable(xDataPilotTable/*, log*/, param); + assertTrue("before failed.", _xDataPilotTable.before()); + assertTrue("_getOutputRange failed.", _xDataPilotTable._getOutputRange()) ; +// assertTrue("_refresh failed.", _xDataPilotTable._refresh()) ; // _XDataPilotDescriptor - XDataPilotDescriptor xDataPilotDescriptor = (XDataPilotDescriptor) + XDataPilotDescriptor xDataPilotDescriptor = UnoRuntime.queryInterface(XDataPilotDescriptor.class, mDataPilotTableObject); _XDataPilotDescriptor _xDataPilotDescriptor = - new _XDataPilotDescriptor(xDataPilotDescriptor, log, param); - assure("before failed.", _xDataPilotDescriptor.before()); - assure("_setTag failed.", _xDataPilotDescriptor._setTag()) ; - assure("_getTag failed.", _xDataPilotDescriptor._getTag()) ; - assure("_getFilterDescriptor failed.", _xDataPilotDescriptor._getFilterDescriptor()) ; - assure("_getDataPilotFields failed.", _xDataPilotDescriptor._getDataPilotFields()) ; - assure("_getColumnFields failed.", _xDataPilotDescriptor._getColumnFields()) ; - assure("_getRowFields failed.", _xDataPilotDescriptor._getRowFields()) ; - assure("_getDataFields failed.", _xDataPilotDescriptor._getDataFields()) ; - assure("_getHiddenFields failed.", _xDataPilotDescriptor._getHiddenFields()) ; - assure("_getPageFields failed.", _xDataPilotDescriptor._getPageFields()) ; - assure("_setSourceRange failed.", _xDataPilotDescriptor._setSourceRange()) ; - assure("_getSourceRange failed.", _xDataPilotDescriptor._getSourceRange()) ; + new _XDataPilotDescriptor(xDataPilotDescriptor/*, log*/, param); + assertTrue("before failed.", _xDataPilotDescriptor.before()); + assertTrue("_setTag failed.", _xDataPilotDescriptor._setTag()) ; + assertTrue("_getTag failed.", _xDataPilotDescriptor._getTag()) ; + assertTrue("_getFilterDescriptor failed.", _xDataPilotDescriptor._getFilterDescriptor()) ; + assertTrue("_getDataPilotFields failed.", _xDataPilotDescriptor._getDataPilotFields()) ; + assertTrue("_getColumnFields failed.", _xDataPilotDescriptor._getColumnFields()) ; + assertTrue("_getRowFields failed.", _xDataPilotDescriptor._getRowFields()) ; + assertTrue("_getDataFields failed.", _xDataPilotDescriptor._getDataFields()) ; + assertTrue("_getHiddenFields failed.", _xDataPilotDescriptor._getHiddenFields()) ; + assertTrue("_getPageFields failed.", _xDataPilotDescriptor._getPageFields()) ; + assertTrue("_setSourceRange failed.", _xDataPilotDescriptor._setSourceRange()) ; + assertTrue("_getSourceRange failed.", _xDataPilotDescriptor._getSourceRange()) ; } /** * create an environment for the test */ - public void before() { - Object oInterface = null; - XSpreadsheetDocument xSheetDoc = null; + @Before public void before() { +// Object oInterface = null; + + // SOfficeFactory SOF = SOfficeFactory.getFactory( (XMultiServiceFactory)param.getMSF() ); + final XMultiServiceFactory xMsf = UnoRuntime.queryInterface(XMultiServiceFactory.class, connection.getComponentContext().getServiceManager()); + SOfficeFactory SOF = SOfficeFactory.getFactory(xMsf); - SOfficeFactory SOF = SOfficeFactory.getFactory( (XMultiServiceFactory)param.getMSF() ); + param = new TestParameters(); + param.put("ServiceFactory", xMsf); // the cell range CellRangeAddress sCellRangeAdress = new CellRangeAddress(); @@ -174,7 +196,7 @@ public class CheckDataPilot extends ComplexTestCase { sCellAdress.Row = 8; try { - log.println( "Creating a Spreadsheet document" ); + System.out.println( "Creating a Spreadsheet document" ); xSheetDoc = SOF.createCalcDoc(null); } catch (com.sun.star.uno.Exception e) { // Some exception occures.FAILED @@ -182,11 +204,11 @@ public class CheckDataPilot extends ComplexTestCase { throw new StatusException( "Couldn't create document", e ); } - log.println("Getting a sheet"); - XSpreadsheets xSpreadsheets = (XSpreadsheets)xSheetDoc.getSheets(); + System.out.println("Getting a sheet"); + XSpreadsheets xSpreadsheets = xSheetDoc.getSheets(); XSpreadsheet oSheet = null; XSpreadsheet oSheet2 = null; - XIndexAccess oIndexAccess = (XIndexAccess) + XIndexAccess oIndexAccess = UnoRuntime.queryInterface(XIndexAccess.class, xSpreadsheets); try { @@ -206,7 +228,7 @@ public class CheckDataPilot extends ComplexTestCase { } try { - log.println("Filling a table"); + System.out.println("Filling a table"); for (int i = 1; i < mMaxFieldIndex; i++) { oSheet.getCellByPosition(i, 0).setFormula("Col" + i); oSheet.getCellByPosition(0, i).setFormula("Row" + i); @@ -215,10 +237,13 @@ public class CheckDataPilot extends ComplexTestCase { } for (int i = 1; i < mMaxFieldIndex; i++) - for (int j = 1; j < mMaxFieldIndex; j++) { + { + for (int j = 1; j < mMaxFieldIndex; j++) + { oSheet.getCellByPosition(i, j).setValue(i * (j + 1)); oSheet2.getCellByPosition(i, j).setValue(i * (j + 2)); } + } } catch (com.sun.star.lang.IndexOutOfBoundsException e) { e.printStackTrace(); throw new StatusException("Couldn't fill some cells", e); @@ -244,8 +269,8 @@ public class CheckDataPilot extends ComplexTestCase { // create the test objects - log.println("Getting test objects") ; - XDataPilotTablesSupplier DPTS = (XDataPilotTablesSupplier) + System.out.println("Getting test objects") ; + XDataPilotTablesSupplier DPTS = UnoRuntime.queryInterface(XDataPilotTablesSupplier.class, oSheet); XDataPilotTables DPT = DPTS.getDataPilotTables(); XDataPilotDescriptor DPDsc = DPT.createDataPilotDescriptor(); @@ -254,7 +279,7 @@ public class CheckDataPilot extends ComplexTestCase { XPropertySet fieldPropSet = null; try { Object oDataPilotField = DPDsc.getDataPilotFields().getByIndex(0); - fieldPropSet = (XPropertySet) + fieldPropSet = UnoRuntime.queryInterface(XPropertySet.class, oDataPilotField); } catch (com.sun.star.lang.WrappedTargetException e) { e.printStackTrace(); @@ -283,7 +308,7 @@ public class CheckDataPilot extends ComplexTestCase { throw new StatusException("Couldn't create a test environment", e); } - log.println("Insert the DataPilotTable"); + System.out.println("Insert the DataPilotTable"); if (DPT.hasByName("DataPilotTable")) { DPT.removeByName("DataPilotTable"); } @@ -326,4 +351,53 @@ public class CheckDataPilot extends ComplexTestCase { } + /* + * this method closes a calc document and resets the corresponding class variable xSheetDoc + */ + protected boolean closeSpreadsheetDocument() { + boolean worked = true; + + System.out.println(" disposing xSheetDoc "); + + try { + XCloseable oCloser = UnoRuntime.queryInterface( + XCloseable.class, xSheetDoc); + oCloser.close(true); + } catch (com.sun.star.util.CloseVetoException e) { + worked = false; + System.out.println("Couldn't close document"); + } catch (com.sun.star.lang.DisposedException e) { + worked = false; + System.out.println("Document already disposed"); + } catch (java.lang.NullPointerException e) { + worked = false; + System.out.println("Couldn't get XCloseable"); + } + + xSheetDoc = null; + + return worked; + } + + @After public void after() + { + closeSpreadsheetDocument(); + } + + + @BeforeClass public static void setUpConnection() throws Exception { + System.out.println("setUpConnection()"); + connection.setUp(); + } + + @AfterClass public static void tearDownConnection() + throws InterruptedException, com.sun.star.uno.Exception + { + System.out.println("tearDownConnection()"); + connection.tearDown(); + } + + private static final OfficeConnection connection = new OfficeConnection(); + + } diff --git a/sc/qa/complex/dataPilot/interfaceTests/sheet/_XDataPilotDescriptor.java b/sc/qa/complex/dataPilot/_XDataPilotDescriptor.java index 8358e5bb6106..e611d8f4e147 100644 --- a/sc/qa/complex/dataPilot/interfaceTests/sheet/_XDataPilotDescriptor.java +++ b/sc/qa/complex/dataPilot/_XDataPilotDescriptor.java @@ -25,7 +25,7 @@ * ************************************************************************/ -package complex.dataPilot.interfaceTests.sheet; +package complex.dataPilot; import com.sun.star.beans.XPropertySet; import com.sun.star.container.XIndexAccess; @@ -34,11 +34,11 @@ import com.sun.star.sheet.DataPilotFieldOrientation; import com.sun.star.sheet.XDataPilotDescriptor; import com.sun.star.table.CellRangeAddress; import com.sun.star.uno.UnoRuntime; -import lib.MultiMethodTest; -import lib.Status; +// import lib.MultiMethodTest; +// import lib.Status; //import lib.StatusException; import lib.TestParameters; -import share.LogWriter; +// import share.LogWriter; /** * Testing <code>com.sun.star.sheet.XDataPilotDescriptor</code> @@ -81,29 +81,29 @@ public class _XDataPilotDescriptor { /** * The log writer */ - private LogWriter log = null; +// private LogWriter log = null; /** * Constructor: gets the object to test, a logger and the test parameters * @param xObj The test object - * @param log A log writer * @param param The test parameters */ - public _XDataPilotDescriptor(XDataPilotDescriptor xObj, - LogWriter log, TestParameters param) { + public _XDataPilotDescriptor(XDataPilotDescriptor xObj/*, + LogWriter log*/, TestParameters param) { oObj = xObj; - this.log = log; + // this.log = log; this.param = param; } /** * Retrieves object relations. - * @throws StatusException If one of relations not found. - */ + + * @return + */ public boolean before() { Integer amount = (Integer)param.get("FIELDSAMOUNT"); if (amount == null) { - log.println("Relation 'FIELDSAMOUNT' not found"); + System.out.println("Relation 'FIELDSAMOUNT' not found"); return false; } tEnvFieldsAmount = amount.intValue(); @@ -118,7 +118,8 @@ public class _XDataPilotDescriptor { * <ul> * <li> <code> setSourceRange() </code> : to have current source range </li> * </ul> - */ + * @return + */ public boolean _getSourceRange(){ // requiredMethod("setSourceRange()"); boolean bResult = true; @@ -144,7 +145,8 @@ public class _XDataPilotDescriptor { * <li> <code> getHiddenFields() </code> </li> * <li> <code> getPageFields() </code> </li> * </ul> - */ + * @return + */ public boolean _setSourceRange(){ /* executeMethod("getColumnFields()") ; executeMethod("getRowFields()") ; @@ -167,7 +169,8 @@ public class _XDataPilotDescriptor { * <ul> * <li> <code> setTag() </code> : to have current tag </li> * </ul> - */ + * @return + */ public boolean _getTag(){ // requiredMethod("setTag()"); boolean bResult = true; @@ -181,7 +184,8 @@ public class _XDataPilotDescriptor { /** * Test just calls the method. <p> * Has <b> OK </b> status if the method successfully returns. <p> - */ + * @return + */ public boolean _setTag(){ oObj.setTag(sTag); return true; @@ -195,22 +199,23 @@ public class _XDataPilotDescriptor { * Has <b> OK </b> status if returned value isn't null, number of fields * goten from returned value is less than number of fields obtained by relation * and no exceptions were thrown. <p> - */ + * @return + */ public boolean _getDataPilotFields(){ boolean bResult = true; XIndexAccess IA = null; IA = oObj.getDataPilotFields(); if (IA == null) { - log.println("Returned value is null."); + System.out.println("Returned value is null."); return false; - } else {log.println("getDataPilotFields returned not Null value -- OK");} + } else {System.out.println("getDataPilotFields returned not Null value -- OK");} fieldsAmount = IA.getCount(); if (fieldsAmount < tEnvFieldsAmount) { - log.println("Number of fields is less than number goten by relation."); + System.out.println("Number of fields is less than number goten by relation."); return false; - } else {log.println("count of returned fields -- OK");} + } else {System.out.println("count of returned fields -- OK");} fieldsNames = new String[tEnvFieldsAmount]; int i = -1 ; @@ -220,24 +225,23 @@ public class _XDataPilotDescriptor { try { field = IA.getByIndex(i); } catch(com.sun.star.lang.WrappedTargetException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false; } catch(com.sun.star.lang.IndexOutOfBoundsException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false; } - XNamed named = (XNamed) - UnoRuntime.queryInterface(XNamed.class, field); + XNamed named = UnoRuntime.queryInterface(XNamed.class, field); String name = named.getName(); - log.println("Field : '" + name + "' ... ") ; + System.out.println("Field : '" + name + "' ... ") ; if (!name.equals("Data")) { fieldsNames[cnt] = name ; - XPropertySet props = (XPropertySet) + XPropertySet props = UnoRuntime.queryInterface(XPropertySet.class, field); try { @@ -245,44 +249,49 @@ public class _XDataPilotDescriptor { case 0 : props.setPropertyValue("Orientation", DataPilotFieldOrientation.COLUMN); - log.println(" Column") ; + System.out.println(" Column") ; break; case 1 : props.setPropertyValue("Orientation", DataPilotFieldOrientation.ROW); - log.println(" Row") ; + System.out.println(" Row") ; break; case 2 : props.setPropertyValue("Orientation", DataPilotFieldOrientation.DATA); - log.println(" Data") ; + System.out.println(" Data") ; break; case 3 : props.setPropertyValue("Orientation", DataPilotFieldOrientation.HIDDEN); - log.println(" Hidden") ; + System.out.println(" Hidden") ; break; case 4 : props.setPropertyValue("Orientation", DataPilotFieldOrientation.PAGE); - log.println(" Page") ; + System.out.println(" Page") ; props.setPropertyValue("CurrentPage", "20"); break; } } catch (com.sun.star.lang.WrappedTargetException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false; } catch (com.sun.star.lang.IllegalArgumentException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false; } catch (com.sun.star.beans.PropertyVetoException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false; } catch (com.sun.star.beans.UnknownPropertyException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false; } - if (++cnt > 4) break; - } else { + if (++cnt > 4) + { + break; + } + } + else + { return false; } } @@ -299,10 +308,11 @@ public class _XDataPilotDescriptor { * <ul> * <li> <code> getDataPilotFields() </code> : to have array of field names </li> * </ul> - */ + * @return + */ public boolean _getColumnFields(){ // requiredMethod("getDataPilotFields()"); - log.println("getColumnFields") ; + System.out.println("getColumnFields") ; XIndexAccess IA = oObj.getColumnFields(); return CheckNames(IA, 0); } @@ -316,10 +326,11 @@ public class _XDataPilotDescriptor { * <ul> * <li> <code> getDataPilotFields() </code> : to have array of field names </li> * </ul> - */ + * @return + */ public boolean _getDataFields(){ // requiredMethod("getDataPilotFields()"); - log.println("getDataFields") ; + System.out.println("getDataFields") ; XIndexAccess IA = oObj.getDataFields(); return CheckNames(IA, 2); } @@ -333,10 +344,11 @@ public class _XDataPilotDescriptor { * <ul> * <li> <code> getDataPilotFields() </code> : to have array of field names </li> * </ul> - */ + * @return + */ public boolean _getHiddenFields(){ // requiredMethod("getDataPilotFields()"); - log.println("getHiddenFields") ; + System.out.println("getHiddenFields") ; XIndexAccess IA = oObj.getHiddenFields(); return CheckNames(IA, 3); } @@ -350,10 +362,11 @@ public class _XDataPilotDescriptor { * <ul> * <li> <code> getDataPilotFields() </code> : to have array of field names </li> * </ul> - */ + * @return + */ public boolean _getRowFields(){ // requiredMethod("getDataPilotFields()"); - log.println("getRowFields") ; + System.out.println("getRowFields") ; XIndexAccess IA = oObj.getRowFields(); boolean bResult = CheckNames(IA, 1); return bResult; @@ -367,10 +380,11 @@ public class _XDataPilotDescriptor { * <ul> * <li> <code> getDataPilotFields() </code> : to have array of field names </li> * </ul> - */ + * @return + */ public boolean _getPageFields(){ // requiredMethod("getDataPilotFields()"); - log.println("getPageFields") ; + System.out.println("getPageFields") ; XIndexAccess IA = oObj.getPageFields(); boolean bResult = CheckNames(IA, 4); return bResult; @@ -380,7 +394,8 @@ public class _XDataPilotDescriptor { * Test calls the method and checks returned value. <p> * Has <b> OK </b> status if returned value isn't null * and no exceptions were thrown. <p> - */ + * @return + */ public boolean _getFilterDescriptor(){ boolean bResult = oObj.getFilterDescriptor() != null; return bResult; @@ -396,46 +411,46 @@ public class _XDataPilotDescriptor { * false otherwise * @see com.sun.star.container.XNamed */ - boolean CheckNames(XIndexAccess IA, int rem) { + private boolean CheckNames(XIndexAccess IA, int rem) { String name = null; if (IA == null) { - log.println("Null retruned.") ; + System.out.println("Null retruned.") ; return false ; } if (fieldsNames[rem] == null) { - log.println("No fields were set to this orientation - cann't check result") ; + System.out.println("No fields were set to this orientation - cann't check result") ; return true ; } if (IA.getCount() == 0) { - log.println("No fields found. Must be at least '" + System.out.println("No fields found. Must be at least '" + fieldsNames[rem] + "'") ; return false ; } try { - log.println("Fields returned ") ; + System.out.println("Fields returned ") ; for (int i = 0; i < IA.getCount(); i++) { Object field = IA.getByIndex(i); - XNamed named = (XNamed)UnoRuntime.queryInterface + XNamed named = UnoRuntime.queryInterface (XNamed.class, field); name = named.getName(); - log.println(" " + name) ; + System.out.println(" " + name) ; if (fieldsNames[rem].equals(name)) { - log.println(" - OK") ; + System.out.println(" - OK") ; return true ; } } } catch (com.sun.star.lang.WrappedTargetException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false ; } catch (com.sun.star.lang.IndexOutOfBoundsException e) { - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); return false ; } - log.println(" - FAILED (field " + fieldsNames[rem] + " was not found.") ; + System.out.println(" - FAILED (field " + fieldsNames[rem] + " was not found.") ; return false ; } diff --git a/sc/qa/complex/dataPilot/interfaceTests/sheet/_XDataPilotTable.java b/sc/qa/complex/dataPilot/_XDataPilotTable.java index d7f6e81b91e5..e27daffab985 100644 --- a/sc/qa/complex/dataPilot/interfaceTests/sheet/_XDataPilotTable.java +++ b/sc/qa/complex/dataPilot/_XDataPilotTable.java @@ -25,16 +25,16 @@ * ************************************************************************/ -package complex.dataPilot.interfaceTests.sheet; +package complex.dataPilot; import com.sun.star.sheet.XDataPilotTable; import com.sun.star.table.CellAddress; import com.sun.star.table.CellRangeAddress; import com.sun.star.table.XCell; -import lib.Status; +// import lib.Status; //import lib.StatusException; import lib.TestParameters; -import share.LogWriter; +// import share.LogWriter; /** * Testing <code>com.sun.star.sheet.XDataPilotTable</code> @@ -71,18 +71,18 @@ public class _XDataPilotTable { /** * The log writer */ - private LogWriter log = null; + // private LogWriter log = null; /** * Constructor: gets the object to test, a logger and the test parameters * @param xObj The test object - * @param log A log writer + * @param param The test parameters */ - public _XDataPilotTable(XDataPilotTable xObj, - LogWriter log, TestParameters param) { + public _XDataPilotTable(XDataPilotTable xObj/*, + LogWriter log*/, TestParameters param) { oObj = xObj; - this.log = log; + // this.log = log; this.param = param; } @@ -94,7 +94,7 @@ public class _XDataPilotTable { if (xCellForChange == null || OutputRange == null || xCellForCheck == null) { - log.println("Relation not found"); + System.out.println("Relation not found"); return false; } return true; @@ -103,7 +103,8 @@ public class _XDataPilotTable { * Test calls the method and checks returned value using value obtained by * object relation <code>'OUTPUTRANGE'</code>. <p> * Has <b> OK </b> status if values are equal. <p> - */ + * @return + */ public boolean _getOutputRange(){ boolean bResult = true; CellRangeAddress objRange = oObj.getOutputRange(); @@ -119,13 +120,14 @@ public class _XDataPilotTable { * relation 'CELLFORCHECK'.<p> * Has <b>OK</b> status if value of the cell obtained by object relation * 'CELLFORCHECK' is changed. <p> - */ + * @return + */ public boolean _refresh(){ xCellForChange.setValue(changeValue); double oldData = xCellForCheck.getValue(); oObj.refresh(); double newData = xCellForCheck.getValue(); - log.println("Old data:" + oldData + "; new data:" + newData); + System.out.println("Old data:" + oldData + "; new data:" + newData); return oldData != newData; } diff --git a/sc/qa/complex/dataPilot/interfaceTests/container/_XNamed.java b/sc/qa/complex/dataPilot/_XNamed.java index 97763be2b199..ff4c647307d5 100644 --- a/sc/qa/complex/dataPilot/interfaceTests/container/_XNamed.java +++ b/sc/qa/complex/dataPilot/_XNamed.java @@ -25,12 +25,12 @@ * ************************************************************************/ -package complex.dataPilot.interfaceTests.container; +package complex.dataPilot; import com.sun.star.container.XNamed; import lib.TestParameters; -import share.LogWriter; -import util.utils; +// import share.LogWriter; +// import util.utils; /** * Testing <code>com.sun.star.container.XNamed</code> @@ -64,7 +64,7 @@ public class _XNamed { /** * The log writer */ - private LogWriter log = null; + // private LogWriter log = null; /** * Constructor: gets the object to test, a logger and the test parameters @@ -72,9 +72,9 @@ public class _XNamed { * @param log A log writer * @param param The test parameters */ - public _XNamed(XNamed xObj, LogWriter log, TestParameters param) { + public _XNamed(XNamed xObj/*, LogWriter log*/, TestParameters param) { oObj = xObj; - this.log = log; + // this.log = log; this.param = param; } @@ -87,7 +87,7 @@ public class _XNamed { public boolean _getName() { // write to log what we try next - log.println( "test for getName()" ); + System.out.println( "test for getName()" ); boolean result = true; boolean loc_result = true; @@ -95,10 +95,16 @@ public class _XNamed { String NewName = null; loc_result = ((name = oObj.getName()) != null); - log.println("getting the name \"" + name + "\""); - - if (loc_result) log.println("... getName() - OK"); - else log.println("... getName() - FAILED"); + System.out.println("getting the name \"" + name + "\""); + + if (loc_result) + { + System.out.println("... getName() - OK"); + } + else + { + System.out.println("... getName() - FAILED"); + } result &= loc_result; return result; } @@ -121,23 +127,29 @@ public class _XNamed { */ public boolean _setName(){ // requiredMethod("getName()"); - log.println("testing setName() ... "); + System.out.println("testing setName() ... "); String oldName = oObj.getName(); String NewName = oldName == null ? "XNamed" : oldName + "X" ; boolean result = true; boolean loc_result = true; - log.println("set the name of object to \"" + NewName + "\""); + System.out.println("set the name of object to \"" + NewName + "\""); oObj.setName(NewName); - log.println("check that container has element with this name"); + System.out.println("check that container has element with this name"); String name = oObj.getName(); - log.println("getting the name \"" + name + "\""); + System.out.println("getting the name \"" + name + "\""); loc_result = name.equals(NewName); - if (loc_result) log.println("... setName() - OK"); - else log.println("... setName() - FAILED"); + if (loc_result) + { + System.out.println("... setName() - OK"); + } + else + { + System.out.println("... setName() - FAILED"); + } result &= loc_result; oObj.setName(oldName); return result; diff --git a/sc/qa/complex/dataPilot/interfaceTests/beans/_XPropertySet.java b/sc/qa/complex/dataPilot/_XPropertySet.java index 57d6474f51b8..e598a0c28890 100644 --- a/sc/qa/complex/dataPilot/interfaceTests/beans/_XPropertySet.java +++ b/sc/qa/complex/dataPilot/_XPropertySet.java @@ -25,7 +25,7 @@ * ************************************************************************/ -package complex.dataPilot.interfaceTests.beans; +package complex.dataPilot; import com.sun.star.beans.Property; import com.sun.star.beans.PropertyAttribute; @@ -38,7 +38,7 @@ import com.sun.star.lang.EventObject; import java.util.Random; import java.util.StringTokenizer; import lib.TestParameters; -import share.LogWriter; +// import share.LogWriter; //import lib.MultiMethodTest; import util.ValueChanger; import util.utils; @@ -72,7 +72,7 @@ public class _XPropertySet { /** * The log writer */ - private LogWriter log = null; + // private LogWriter log = null; /** * Flag that indicates change listener was called. @@ -144,9 +144,9 @@ public class _XPropertySet { * @param log A log writer * @param param The test parameters */ - public _XPropertySet(XPropertySet xObj, LogWriter log, TestParameters param) { + public _XPropertySet(XPropertySet xObj/*, LogWriter log*/, TestParameters param) { oObj = xObj; - this.log = log; + // this.log = log; this.param = param; } @@ -166,7 +166,7 @@ public class _XPropertySet { XPropertySetInfo propertySetInfo = oObj.getPropertySetInfo(); if (propertySetInfo == null) { - log.println("getPropertySetInfo() method returned null"); + System.out.println("getPropertySetInfo() method returned null"); String[] ptt = (String[]) param.get("PTT"); PTT.normal=ptt[0]; PTT.bound=ptt[1]; @@ -197,7 +197,7 @@ public class _XPropertySet { boolean result = true; if ( PTT.bound.equals("none") ) { - log.println("*** No bound properties found ***"); + System.out.println("*** No bound properties found ***"); } else { try { oObj.addPropertyChangeListener(PTT.bound,PClistener); @@ -205,25 +205,25 @@ public class _XPropertySet { oObj.setPropertyValue(PTT.bound, ValueChanger.changePValue(gValue)); } catch (com.sun.star.beans.PropertyVetoException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.IllegalArgumentException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.beans.UnknownPropertyException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.WrappedTargetException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } // end of try-catch result = propertyChanged; if (!propertyChanged) { - log.println("propertyChangeListener wasn't called for '"+ + System.out.println("propertyChangeListener wasn't called for '"+ PTT.bound+"'"); } } //endif @@ -252,7 +252,7 @@ public class _XPropertySet { boolean result = true; if ( PTT.constrained.equals("none") ) { - log.println("*** No constrained properties found ***"); + System.out.println("*** No constrained properties found ***"); } else { try { oObj.addVetoableChangeListener(PTT.constrained,VClistener); @@ -260,25 +260,25 @@ public class _XPropertySet { oObj.setPropertyValue(PTT.constrained, ValueChanger.changePValue(gValue)); } catch (com.sun.star.beans.PropertyVetoException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.IllegalArgumentException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.beans.UnknownPropertyException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.WrappedTargetException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } // end of try-catch result = vetoableChanged; if (!vetoableChanged) { - log.println("vetoableChangeListener wasn't called for '"+ + System.out.println("vetoableChangeListener wasn't called for '"+ PTT.constrained+"'"); } } //endif @@ -310,7 +310,7 @@ public class _XPropertySet { boolean result = true; if ( PTT.normal.equals("none") ) { - log.println("*** No changeable properties found ***"); + System.out.println("*** No changeable properties found ***"); } else { try { gValue = oObj.getPropertyValue(PTT.normal); @@ -318,21 +318,21 @@ public class _XPropertySet { oObj.setPropertyValue(PTT.normal, sValue); sValue = oObj.getPropertyValue(PTT.normal); } catch (com.sun.star.beans.PropertyVetoException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.normal+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.IllegalArgumentException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.normal+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.beans.UnknownPropertyException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.normal+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.WrappedTargetException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.normal+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } // end of try-catch result = !gValue.equals(sValue); } //endif @@ -361,21 +361,21 @@ public class _XPropertySet { if ( PTT.normal.equals("none") ) { toCheck = oObj.getPropertySetInfo().getProperties()[0].Name; - log.println("All properties are Read Only"); - log.println("Using: "+toCheck); + System.out.println("All properties are Read Only"); + System.out.println("Using: "+toCheck); } try { Object gValue = oObj.getPropertyValue(toCheck); } catch (com.sun.star.beans.UnknownPropertyException e) { - log.println("Exception occured while trying to get property '"+ + System.out.println("Exception occured while trying to get property '"+ PTT.normal+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); result = false; } catch (com.sun.star.lang.WrappedTargetException e) { - log.println("Exception occured while trying to get property '"+ + System.out.println("Exception occured while trying to get property '"+ PTT.normal+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); result = false; } // end of try-catch @@ -402,7 +402,7 @@ public class _XPropertySet { boolean result = true; if ( PTT.bound.equals("none") ) { - log.println("*** No bound properties found ***"); + System.out.println("*** No bound properties found ***"); } else { try { propertyChanged = false; @@ -411,26 +411,26 @@ public class _XPropertySet { oObj.setPropertyValue(PTT.bound, ValueChanger.changePValue(gValue)); } catch (com.sun.star.beans.PropertyVetoException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.IllegalArgumentException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.beans.UnknownPropertyException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.WrappedTargetException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.bound+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } // end of try-catch result = !propertyChanged; if (propertyChanged) { - log.println("propertyChangeListener was called after removing"+ + System.out.println("propertyChangeListener was called after removing"+ " for '"+PTT.bound+"'"); } } //endif @@ -460,7 +460,7 @@ public class _XPropertySet { boolean result = true; if ( PTT.constrained.equals("none") ) { - log.println("*** No constrained properties found ***"); + System.out.println("*** No constrained properties found ***"); } else { try { oObj.removeVetoableChangeListener(PTT.constrained,VClistener); @@ -468,26 +468,26 @@ public class _XPropertySet { oObj.setPropertyValue(PTT.constrained, ValueChanger.changePValue(gValue)); } catch (com.sun.star.beans.PropertyVetoException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.IllegalArgumentException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.beans.UnknownPropertyException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } catch (com.sun.star.lang.WrappedTargetException e) { - log.println("Exception occured while trying to change "+ + System.out.println("Exception occured while trying to change "+ "property '"+ PTT.constrained+"'"); - e.printStackTrace((java.io.PrintWriter)log); + e.printStackTrace(); } // end of try-catch result = !vetoableChanged; if (vetoableChanged) { - log.println("vetoableChangeListener was called after "+ + System.out.println("vetoableChangeListener was called after "+ "removing for '"+PTT.constrained+"'"); } } //endif @@ -512,7 +512,7 @@ public class _XPropertySet { Property property = properties[i]; String name = property.Name; - log.println("Checking '"+name+"'"); + System.out.println("Checking '"+name+"'"); boolean isWritable = ((property.Attributes & PropertyAttribute.READONLY) == 0); boolean isNotNull = ((property.Attributes & @@ -523,7 +523,7 @@ public class _XPropertySet { PropertyAttribute.CONSTRAINED) != 0); boolean canChange = false; - if ( !isWritable ) log.println("Property '"+name+"' is READONLY"); + if ( !isWritable ) System.out.println("Property '"+name+"' is READONLY"); if (name.endsWith("URL")) isWritable = false; if (name.startsWith("Fill")) isWritable = false; @@ -552,11 +552,11 @@ public class _XPropertySet { //get a random bound property PTT.bound=getRandomString(bound); - log.println("Bound: "+PTT.bound); + System.out.println("Bound: "+PTT.bound); //get a random constrained property PTT.constrained=getRandomString(constrained); - log.println("Constrained: "+PTT.constrained); + System.out.println("Constrained: "+PTT.constrained); //get a random normal property PTT.normal=getRandomString(normal); @@ -588,39 +588,39 @@ public class _XPropertySet { boolean hasChanged = false; try { Object getProp = oObj.getPropertyValue(name); - log.println("Getting: "+getProp); + System.out.println("Getting: "+getProp); Object setValue = null; if (getProp != null) { if (!utils.isVoid(getProp)) setValue = ValueChanger.changePValue(getProp); - else log.println("Property '"+name+ + else System.out.println("Property '"+name+ "' is void but MAYBEVOID isn't set"); - } else log.println("Property '"+name+"'is null and can't be changed"); + } else System.out.println("Property '"+name+"'is null and can't be changed"); if (name.equals("LineStyle")) setValue = null; if (setValue != null) { oObj.setPropertyValue(name, setValue); - log.println("Setting to :"+setValue); + System.out.println("Setting to :"+setValue); hasChanged = (! getProp.equals(oObj.getPropertyValue(name))); - } else log.println("Couldn't change Property '"+name+"'"); + } else System.out.println("Couldn't change Property '"+name+"'"); } catch (com.sun.star.beans.PropertyVetoException e) { - log.println("'" + name + "' throws exception '" + e + "'"); - e.printStackTrace((java.io.PrintWriter)log); + System.out.println("'" + name + "' throws exception '" + e + "'"); + e.printStackTrace(); } catch (com.sun.star.lang.IllegalArgumentException e) { - log.println("'" + name + "' throws exception '" + e + "'"); - e.printStackTrace((java.io.PrintWriter)log); + System.out.println("'" + name + "' throws exception '" + e + "'"); + e.printStackTrace(); } catch (com.sun.star.beans.UnknownPropertyException e) { - log.println("'" + name + "' throws exception '" + e + "'"); - e.printStackTrace((java.io.PrintWriter)log); + System.out.println("'" + name + "' throws exception '" + e + "'"); + e.printStackTrace(); } catch (com.sun.star.lang.WrappedTargetException e) { - log.println("'" + name + "' throws exception '" + e + "'"); - e.printStackTrace((java.io.PrintWriter)log); + System.out.println("'" + name + "' throws exception '" + e + "'"); + e.printStackTrace(); } catch (com.sun.star.uno.RuntimeException e) { - log.println("'" + name + "' throws exception '" + e + "'"); - e.printStackTrace((java.io.PrintWriter)log); + System.out.println("'" + name + "' throws exception '" + e + "'"); + e.printStackTrace(); } catch (java.lang.ArrayIndexOutOfBoundsException e) { - log.println("'" + name + "' throws exception '" + e + "'"); - e.printStackTrace((java.io.PrintWriter)log); + System.out.println("'" + name + "' throws exception '" + e + "'"); + e.printStackTrace(); } return hasChanged; diff --git a/sc/qa/complex/dataPilot/interfaceTests/beans/makefile.mk b/sc/qa/complex/dataPilot/interfaceTests/beans/makefile.mk index 6ef9f7456cbb..22b29f5e0585 100644 --- a/sc/qa/complex/dataPilot/interfaceTests/beans/makefile.mk +++ b/sc/qa/complex/dataPilot/interfaceTests/beans/makefile.mk @@ -25,10 +25,10 @@ # #************************************************************************* -PRJ = ..$/..$/..$/..$/.. +PRJ = ../../../../.. TARGET = DataPilotInterfaceBeans PRJNAME = sc -PACKAGE = complex$/dataPilot$/interfaceTests$/beans +PACKAGE = complex/dataPilot/interfaceTests/beans # --- Settings ----------------------------------------------------- .INCLUDE: settings.mk @@ -38,7 +38,7 @@ PACKAGE = complex$/dataPilot$/interfaceTests$/beans JARFILES = ridl.jar unoil.jar jurt.jar juh.jar java_uno.jar OOoRunner.jar JAVAFILES = _XPropertySet.java -JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)$/$(PACKAGE)$/$(i:b).class) +JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)/$(PACKAGE)/$(i:b).class) # --- Targets ------------------------------------------------------ diff --git a/sc/qa/complex/dataPilot/interfaceTests/container/makefile.mk b/sc/qa/complex/dataPilot/interfaceTests/container/makefile.mk index 675fe7be9a1c..d8b4321f0fd1 100644 --- a/sc/qa/complex/dataPilot/interfaceTests/container/makefile.mk +++ b/sc/qa/complex/dataPilot/interfaceTests/container/makefile.mk @@ -25,10 +25,10 @@ # #************************************************************************* -PRJ = ..$/..$/..$/..$/.. +PRJ = ../../../../.. TARGET = DataPilotInterfaceContainer PRJNAME = sc -PACKAGE = complex$/dataPilot$/interfaceTests$/container +PACKAGE = complex/dataPilot/interfaceTests/container # --- Settings ----------------------------------------------------- .INCLUDE: settings.mk @@ -38,7 +38,7 @@ PACKAGE = complex$/dataPilot$/interfaceTests$/container JARFILES = ridl.jar unoil.jar jurt.jar juh.jar java_uno.jar OOoRunner.jar JAVAFILES = _XNamed.java -JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)$/$(PACKAGE)$/$(i:b).class) +JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)/$(PACKAGE)/$(i:b).class) # --- Targets ------------------------------------------------------ diff --git a/sc/qa/complex/dataPilot/interfaceTests/sheet/makefile.mk b/sc/qa/complex/dataPilot/interfaceTests/sheet/makefile.mk index 350e3fcb8f19..f62d17614222 100644 --- a/sc/qa/complex/dataPilot/interfaceTests/sheet/makefile.mk +++ b/sc/qa/complex/dataPilot/interfaceTests/sheet/makefile.mk @@ -25,10 +25,10 @@ # #************************************************************************* -PRJ = ..$/..$/..$/..$/.. +PRJ = ../../../../.. TARGET = DataPilotInterfaceSheet PRJNAME = sc -PACKAGE = complex$/dataPilot$/interfaceTests$/sheet +PACKAGE = complex/dataPilot/interfaceTests/sheet # --- Settings ----------------------------------------------------- .INCLUDE: settings.mk @@ -38,7 +38,7 @@ PACKAGE = complex$/dataPilot$/interfaceTests$/sheet JARFILES = ridl.jar unoil.jar jurt.jar juh.jar java_uno.jar OOoRunner.jar JAVAFILES = _XDataPilotDescriptor.java _XDataPilotTable.java -JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)$/$(PACKAGE)$/$(i:b).class) +JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)/$(PACKAGE)/$(i:b).class) # --- Targets ------------------------------------------------------ diff --git a/sc/qa/complex/dataPilot/makefile.mk b/sc/qa/complex/dataPilot/makefile.mk index a0bf1df34d0e..85512f8e5bc4 100644 --- a/sc/qa/complex/dataPilot/makefile.mk +++ b/sc/qa/complex/dataPilot/makefile.mk @@ -25,34 +25,35 @@ # #************************************************************************* -PRJ = ..$/..$/.. -TARGET = DataPilot -PRJNAME = sc -PACKAGE = complex$/dataPilot - -# --- Settings ----------------------------------------------------- -.INCLUDE: settings.mk +.IF "$(OOO_SUBSEQUENT_TESTS)" == "" +nothing .PHONY: +.ELSE +PRJ = ../../.. +PRJNAME = sc +TARGET = qa_complex_datapilot -#----- compile .java files ----------------------------------------- - -JARFILES = ridl.jar unoil.jar jurt.jar juh.jar java_uno.jar OOoRunner.jar -JAVAFILES = CheckDataPilot.java -JAVACLASSFILES = $(foreach,i,$(JAVAFILES) $(CLASSDIR)$/$(PACKAGE)$/$(i:b).class) +.IF "$(OOO_JUNIT_JAR)" != "" +PACKAGE = complex/dataPilot +JAVATESTFILES = \ + CheckDataPilot.java -SUBDIRS = interfaceTests$/beans interfaceTests$/container interfaceTests$/sheet -#----- make a jar from compiled files ------------------------------ +JAVAFILES = $(JAVATESTFILES) \ + _XDataPilotDescriptor.java \ + _XDataPilotTable.java \ + _XNamed.java \ + _XPropertySet.java -MAXLINELENGTH = 100000 +JARFILES = OOoRunner.jar ridl.jar test.jar unoil.jar +EXTRAJARFILES = $(OOO_JUNIT_JAR) -JARCLASSDIRS = $(PACKAGE) -JARTARGET = $(TARGET).jar -JARCOMPRESS = TRUE +.END -# --- Targets ------------------------------------------------------ +.INCLUDE: settings.mk +.INCLUDE: target.mk +.INCLUDE: installationtest.mk -.INCLUDE : target.mk +ALLTAR : javatest +.END -run: - +java -cp $(CLASSPATH) org.openoffice.Runner -TimeOut 0 -tb java_complex -o $(PACKAGE:s#$/#.#).$(JAVAFILES:b) |