UnoAPITest

From Apache OpenOffice Wiki
Jump to: navigation, search

To check the UnoApi there exists a framework implemented in Java. See http://qa.openoffice.org/qadevOOo_doc/index.html

All components which supports Uno-Objects has a QA folder which contains all information to run the UnoApiTest of the module successfully.

$MODULE/qa/unoapi
The folder which contains all necessary files
$MODULE.sce
ScenarioFile: This file contains all known implementation objects of the module.
knownissues.xcl
This file contains a list of all known issues.
makefile.mk
This file is the makefile

How to run the tests

To run the tests you have to start a connectable office and run dmake in the $MODULE/qa/unoapi folder:

./soffice "-accept=pipe,name=$USER;urp;" &   # Unix
 soffice "-accept=pipe,name=%USERNAME%;urp;" # Windows

Note: Since CwsCheckAPI is available the connection via socket is not the default anymore. DEPRECATED: "-accept=socket,host=0,port=8100;urp;"

The call dmake in your module:

cd $MODULE/qa/unoapi
dmake

The result of the tests is shown at the end and could look like this:

***** State for svtools.AccessibleTreeListBoxEntry ******
Whole component: PASSED(with known issues).OK
*********************************************************

Failures that appeared during scenario execution:
         svtools.AccessibleTabBar
1 of 12 tests failed
Job -sce svtools.sce done

Explanations of the test result

**** State for svtools.AccessibleTreeListBoxEntry ******
Whole component: PASSED(with known issues).OK

While running the UnoApiTest of svtools.AccessibleTreeListBoxEntry one ore more interface tests failed but the problem is known and an issue is already written. You will find the issue in the knownissues.xcl

Failures that appeared during scenario execution:
        svtools.AccessibleTabBar
1 of 12 tests failed

One of the object tests failed. In this case svtools.AccessibleTabBar causes an unkown error and needs a deeper investigation. After all one of 12 tests failed.


What should I do with unkown error ?

To validate the ``unkown error`` you can call the CheckAPI script with the failed object as argument, in this example case:

checkapi -o svtools.AccessibleTabBar

This shows you all failures in the test. If you like to run the test with the knownissues.xcl try this:

checkapi -o svtools.AccessibleTabBar -xcl $MODULE/qa/unoapi/knownissues.xcl

Parameter to the testrun

It is possible to use command line parameter in the UnoApiTest. You can also change some default parameter in the RunnerProps file.

Personal tools