diff options
author | Ingrid Halama <iha@openoffice.org> | 2010-05-17 17:04:26 +0200 |
---|---|---|
committer | Ingrid Halama <iha@openoffice.org> | 2010-05-17 17:04:26 +0200 |
commit | 9f124082f800eed4f436203fd309b17fd7584f95 (patch) | |
tree | c270a28e278dcd4f5132cf3a9dd403547e7bfd5d /qadevOOo | |
parent | 4b770dd310a1e1b37abd1728abc2e21f3fb3f129 (diff) |
chart47: #i109770# #i110253# reduce assertions 'already disposed or closed' - don't close the document twice
Diffstat (limited to 'qadevOOo')
26 files changed, 135 insertions, 66 deletions
diff --git a/qadevOOo/tests/java/mod/_sch/AccArea.java b/qadevOOo/tests/java/mod/_sch/AccArea.java index dae93e6d3326..b371f1950558 100644 --- a/qadevOOo/tests/java/mod/_sch/AccArea.java +++ b/qadevOOo/tests/java/mod/_sch/AccArea.java @@ -111,9 +111,11 @@ public class AccArea extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccAxis.java b/qadevOOo/tests/java/mod/_sch/AccAxis.java index e0c6b8901345..2cdecae03aca 100644 --- a/qadevOOo/tests/java/mod/_sch/AccAxis.java +++ b/qadevOOo/tests/java/mod/_sch/AccAxis.java @@ -109,9 +109,11 @@ public class AccAxis extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccDataPoint.java b/qadevOOo/tests/java/mod/_sch/AccDataPoint.java index 45bd6e3e4101..3e94364a0559 100644 --- a/qadevOOo/tests/java/mod/_sch/AccDataPoint.java +++ b/qadevOOo/tests/java/mod/_sch/AccDataPoint.java @@ -110,9 +110,11 @@ public class AccDataPoint extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccDataSeries.java b/qadevOOo/tests/java/mod/_sch/AccDataSeries.java index 4eff500ebba7..2d5ec4fde1d5 100644 --- a/qadevOOo/tests/java/mod/_sch/AccDataSeries.java +++ b/qadevOOo/tests/java/mod/_sch/AccDataSeries.java @@ -110,9 +110,11 @@ public class AccDataSeries extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccDiagram.java b/qadevOOo/tests/java/mod/_sch/AccDiagram.java index 50657c0218ac..9b7f90766fdd 100644 --- a/qadevOOo/tests/java/mod/_sch/AccDiagram.java +++ b/qadevOOo/tests/java/mod/_sch/AccDiagram.java @@ -110,9 +110,11 @@ public class AccDiagram extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccFloor.java b/qadevOOo/tests/java/mod/_sch/AccFloor.java index 9ab1f9542111..37d56815983d 100644 --- a/qadevOOo/tests/java/mod/_sch/AccFloor.java +++ b/qadevOOo/tests/java/mod/_sch/AccFloor.java @@ -135,9 +135,11 @@ public class AccFloor extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccGrid.java b/qadevOOo/tests/java/mod/_sch/AccGrid.java index f92aa0fe82a6..268f53ec8b3d 100644 --- a/qadevOOo/tests/java/mod/_sch/AccGrid.java +++ b/qadevOOo/tests/java/mod/_sch/AccGrid.java @@ -111,9 +111,11 @@ public class AccGrid extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccLegend.java b/qadevOOo/tests/java/mod/_sch/AccLegend.java index a0f29e1e0701..aa46cdb8407d 100644 --- a/qadevOOo/tests/java/mod/_sch/AccLegend.java +++ b/qadevOOo/tests/java/mod/_sch/AccLegend.java @@ -109,9 +109,11 @@ public class AccLegend extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccLegendEntry.java b/qadevOOo/tests/java/mod/_sch/AccLegendEntry.java index 78996d84fa2a..61c221df57e0 100644 --- a/qadevOOo/tests/java/mod/_sch/AccLegendEntry.java +++ b/qadevOOo/tests/java/mod/_sch/AccLegendEntry.java @@ -109,9 +109,11 @@ public class AccLegendEntry extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccStatisticsObject.java b/qadevOOo/tests/java/mod/_sch/AccStatisticsObject.java index d72723ebea62..aafe91fdd3d4 100644 --- a/qadevOOo/tests/java/mod/_sch/AccStatisticsObject.java +++ b/qadevOOo/tests/java/mod/_sch/AccStatisticsObject.java @@ -114,9 +114,11 @@ public class AccStatisticsObject extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccTitle.java b/qadevOOo/tests/java/mod/_sch/AccTitle.java index 4fa56ee8f4f1..0639f19ca4cc 100644 --- a/qadevOOo/tests/java/mod/_sch/AccTitle.java +++ b/qadevOOo/tests/java/mod/_sch/AccTitle.java @@ -109,9 +109,11 @@ public class AccTitle extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccWall.java b/qadevOOo/tests/java/mod/_sch/AccWall.java index 4dc94a173fff..66779421cc0b 100644 --- a/qadevOOo/tests/java/mod/_sch/AccWall.java +++ b/qadevOOo/tests/java/mod/_sch/AccWall.java @@ -134,9 +134,11 @@ public class AccWall extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } } diff --git a/qadevOOo/tests/java/mod/_sch/AccessibleDocumentView.java b/qadevOOo/tests/java/mod/_sch/AccessibleDocumentView.java index a064e7f05a09..9031680f93f1 100644 --- a/qadevOOo/tests/java/mod/_sch/AccessibleDocumentView.java +++ b/qadevOOo/tests/java/mod/_sch/AccessibleDocumentView.java @@ -102,8 +102,11 @@ public class AccessibleDocumentView extends TestCase { * @param log writer to log information while testing */ protected void cleanup( TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChXChartAxis.java b/qadevOOo/tests/java/mod/_sch/ChXChartAxis.java index da12c9e6b57a..f796d5530a9c 100644 --- a/qadevOOo/tests/java/mod/_sch/ChXChartAxis.java +++ b/qadevOOo/tests/java/mod/_sch/ChXChartAxis.java @@ -86,8 +86,11 @@ public class ChXChartAxis extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChXChartData.java b/qadevOOo/tests/java/mod/_sch/ChXChartData.java index fe14322933a5..3236e345b8e6 100644 --- a/qadevOOo/tests/java/mod/_sch/ChXChartData.java +++ b/qadevOOo/tests/java/mod/_sch/ChXChartData.java @@ -73,8 +73,11 @@ public class ChXChartData extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChXChartDataArray.java b/qadevOOo/tests/java/mod/_sch/ChXChartDataArray.java index 35d15d634054..14caeefff8c1 100644 --- a/qadevOOo/tests/java/mod/_sch/ChXChartDataArray.java +++ b/qadevOOo/tests/java/mod/_sch/ChXChartDataArray.java @@ -76,8 +76,11 @@ public class ChXChartDataArray extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChXChartDocument.java b/qadevOOo/tests/java/mod/_sch/ChXChartDocument.java index a51457d5cde1..deafa9922043 100644 --- a/qadevOOo/tests/java/mod/_sch/ChXChartDocument.java +++ b/qadevOOo/tests/java/mod/_sch/ChXChartDocument.java @@ -77,10 +77,16 @@ public class ChXChartDocument extends TestCase { * Disposes Chart documents. */ protected void cleanup(TestParameters Param, PrintWriter log) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); - log.println( " closing xChartDoc2 " ); - util.DesktopTools.closeDoc(doc2); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } + if( doc2!=null ) { + log.println( " closing xChartDoc2" ); + util.DesktopTools.closeDoc(doc2); + doc2 = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChXChartView.java b/qadevOOo/tests/java/mod/_sch/ChXChartView.java index 9d1ea2539bfc..f5476f2d0643 100644 --- a/qadevOOo/tests/java/mod/_sch/ChXChartView.java +++ b/qadevOOo/tests/java/mod/_sch/ChXChartView.java @@ -84,8 +84,11 @@ public class ChXChartView extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChXDataPoint.java b/qadevOOo/tests/java/mod/_sch/ChXDataPoint.java index b6ddb94575b4..0c1647684c75 100644 --- a/qadevOOo/tests/java/mod/_sch/ChXDataPoint.java +++ b/qadevOOo/tests/java/mod/_sch/ChXDataPoint.java @@ -101,8 +101,11 @@ public class ChXDataPoint extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChXDataRow.java b/qadevOOo/tests/java/mod/_sch/ChXDataRow.java index ffc13ad95bb7..69139ea5d902 100644 --- a/qadevOOo/tests/java/mod/_sch/ChXDataRow.java +++ b/qadevOOo/tests/java/mod/_sch/ChXDataRow.java @@ -107,8 +107,11 @@ public class ChXDataRow extends TestCase { * Disposes Chart document. */ protected synchronized void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } diff --git a/qadevOOo/tests/java/mod/_sch/ChartArea.java b/qadevOOo/tests/java/mod/_sch/ChartArea.java index 17a04276aaca..614327f94a1e 100644 --- a/qadevOOo/tests/java/mod/_sch/ChartArea.java +++ b/qadevOOo/tests/java/mod/_sch/ChartArea.java @@ -92,8 +92,11 @@ public class ChartArea extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChartGrid.java b/qadevOOo/tests/java/mod/_sch/ChartGrid.java index 671cfcfe86e3..73a44b810436 100644 --- a/qadevOOo/tests/java/mod/_sch/ChartGrid.java +++ b/qadevOOo/tests/java/mod/_sch/ChartGrid.java @@ -81,8 +81,11 @@ public class ChartGrid extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChartLegend.java b/qadevOOo/tests/java/mod/_sch/ChartLegend.java index 78770c5f94b6..a0dd4fe3ec64 100644 --- a/qadevOOo/tests/java/mod/_sch/ChartLegend.java +++ b/qadevOOo/tests/java/mod/_sch/ChartLegend.java @@ -109,8 +109,11 @@ public class ChartLegend extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChartLine.java b/qadevOOo/tests/java/mod/_sch/ChartLine.java index e2345ba7edb5..950885060f5f 100644 --- a/qadevOOo/tests/java/mod/_sch/ChartLine.java +++ b/qadevOOo/tests/java/mod/_sch/ChartLine.java @@ -79,8 +79,11 @@ public class ChartLine extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_sch/ChartTitle.java b/qadevOOo/tests/java/mod/_sch/ChartTitle.java index b1e47c0ea00b..f88c938693bc 100644 --- a/qadevOOo/tests/java/mod/_sch/ChartTitle.java +++ b/qadevOOo/tests/java/mod/_sch/ChartTitle.java @@ -91,8 +91,11 @@ public class ChartTitle extends TestCase { * Disposes Chart document. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " closing xChartDoc " ); - util.DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** diff --git a/qadevOOo/tests/java/mod/_xmloff/Chart/XMLExporter.java b/qadevOOo/tests/java/mod/_xmloff/Chart/XMLExporter.java index 393ddb7492ce..a5027b3f989d 100644 --- a/qadevOOo/tests/java/mod/_xmloff/Chart/XMLExporter.java +++ b/qadevOOo/tests/java/mod/_xmloff/Chart/XMLExporter.java @@ -95,8 +95,11 @@ public class XMLExporter extends TestCase { * Document disposed here. */ protected void cleanup( TestParameters tParam, PrintWriter log ) { - log.println( " close xChartDoc " ); - DesktopTools.closeDoc(xChartDoc); + if( xChartDoc!=null ) { + log.println( " closing xChartDoc" ); + util.DesktopTools.closeDoc(xChartDoc); + xChartDoc = null; + } } /** |