Conversion.java (75ed6c31) | Conversion.java (25bd9146) |
---|---|
1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 71 unchanged lines hidden (view full) --- 80 public static long nSleep = Long.parseLong(System.getProperty("conversion.sleep", "0")); // Sleep before loadComponentFromURL and storeToURL 81 82 private static OpenOffice aoo = new OpenOffice(); 83 84 private static UnoApp app = null; 85 86 private static DataSheet result; 87 | 1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 71 unchanged lines hidden (view full) --- 80 public static long nSleep = Long.parseLong(System.getProperty("conversion.sleep", "0")); // Sleep before loadComponentFromURL and storeToURL 81 82 private static OpenOffice aoo = new OpenOffice(); 83 84 private static UnoApp app = null; 85 86 private static DataSheet result; 87 |
88 private static int counter = 0; | 88 private static int counter = -1; |
89 90 @BeforeClass 91 public static void beforeClass() throws Exception { 92 aoo.setUnoUrl(OpenOffice.DEFAULT_UNO_URL); 93 aoo.addArgs("-invisible", "-conversionmode", "-hidemenu", "-nofirststartwizard"); 94 app = new UnoApp(aoo); 95 Testspace.prepareDataFile("limit_cfg.ini", aoo.getHome().toString()+"/program"); // Move limitation check file to installation dir 96 result = new DataSheet(getFile("output/" + Conversion.class.getName()+ ".xml")); --- 57 unchanged lines hidden (view full) --- 154 private PropertyValue propertyValue(String name, Object value) { 155 PropertyValue p = new PropertyValue(); 156 p.Name = name; 157 p.Value= value; 158 return p; 159 } 160 161 | 89 90 @BeforeClass 91 public static void beforeClass() throws Exception { 92 aoo.setUnoUrl(OpenOffice.DEFAULT_UNO_URL); 93 aoo.addArgs("-invisible", "-conversionmode", "-hidemenu", "-nofirststartwizard"); 94 app = new UnoApp(aoo); 95 Testspace.prepareDataFile("limit_cfg.ini", aoo.getHome().toString()+"/program"); // Move limitation check file to installation dir 96 result = new DataSheet(getFile("output/" + Conversion.class.getName()+ ".xml")); --- 57 unchanged lines hidden (view full) --- 154 private PropertyValue propertyValue(String name, Object value) { 155 PropertyValue p = new PropertyValue(); 156 p.Name = name; 157 p.Value= value; 158 return p; 159 } 160 161 |
162 @Test(timeout=10 * 60000) | 162 @Test(timeout=5 * 60000) |
163 public void testConversion() throws Exception { 164 try { 165 if (nSleep > 0) 166 Thread.sleep(nSleep); 167 long start = System.currentTimeMillis(); 168 XComponent doc = app.loadDocumentFromURL(sourceFileUrl, 169 propertyValue("Hidden", true), 170 propertyValue("ReadOnly", true), --- 27 unchanged lines hidden --- | 163 public void testConversion() throws Exception { 164 try { 165 if (nSleep > 0) 166 Thread.sleep(nSleep); 167 long start = System.currentTimeMillis(); 168 XComponent doc = app.loadDocumentFromURL(sourceFileUrl, 169 propertyValue("Hidden", true), 170 propertyValue("ReadOnly", true), --- 27 unchanged lines hidden --- |