BasicFunctionTest.java (f9b06548) BasicFunctionTest.java (a622bb93)
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

--- 58 unchanged lines hidden (view full) ---

67 app.stop();
68 app.start();
69 }
70
71
72 @Test
73 public void smokeTest() {
74 File smoketestOutput = new File(aoo.getUserInstallation(), "user/temp");
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

--- 58 unchanged lines hidden (view full) ---

67 app.stop();
68 app.start();
69 }
70
71
72 @Test
73 public void smokeTest() {
74 File smoketestOutput = new File(aoo.getUserInstallation(), "user/temp");
75 prepareData("TestExtension.oxt");
75 File testDir = getFile().getParentFile();
76 File smokeTestDir = new File(testDir, "smoketestdoc");
77 File smokeTestTargetDir = new File(smokeTestDir, "target");
78 prepareData(new File(smokeTestTargetDir, "TestExtension.oxt").getAbsolutePath());
76 // Open sample file smoketestdoc.sxw
79 // Open sample file smoketestdoc.sxw
77 open(prepareData("smoketestdoc.sxw"));
80 open(prepareData(new File(smokeTestTargetDir, "smoketestdoc.odt").getAbsolutePath()));
78 writer.waitForEnabled(10, 2);
79 // Run test cases
80 app.dispatch("vnd.sun.star.script:Standard.Global.StartTestWithDefaultOptions?language=Basic&location=document", 120);
81 String smoketestlog = FileUtil.readFileAsString(new File(smoketestOutput, "smoketest.log"));
82 String testclosurelog = FileUtil.readFileAsString(new File(smoketestOutput, "testclosure.log"));
83 log.info(smoketestlog + "\n" + testclosurelog);
84 assertTrue("No Error", !smoketestlog.contains("error") && !testclosurelog.contains("error"));
85

--- 629 unchanged lines hidden ---
81 writer.waitForEnabled(10, 2);
82 // Run test cases
83 app.dispatch("vnd.sun.star.script:Standard.Global.StartTestWithDefaultOptions?language=Basic&location=document", 120);
84 String smoketestlog = FileUtil.readFileAsString(new File(smoketestOutput, "smoketest.log"));
85 String testclosurelog = FileUtil.readFileAsString(new File(smoketestOutput, "testclosure.log"));
86 log.info(smoketestlog + "\n" + testclosurelog);
87 assertTrue("No Error", !smoketestlog.contains("error") && !testclosurelog.contains("error"));
88

--- 629 unchanged lines hidden ---