KDE PIM/Akonadi/Testing

< KDE PIM‎ | Akonadi
Revision as of 18:08, 21 January 2009 by Vkrause (Talk | contribs) (Document current unittest setup)

Jump to: navigation, search

Akonadi Test and Benchmark Infrastructure

Akonadi Testrunner

Igor's GSoC project, found in kdepimlibs/akonadi/tests/testrunner.

Documentation based on Igor's mail to kde-pim ML:

First you need create a configuration file in KStandardDirs config resource type (try to use: kde4-config --path config, to find the path in my case the path is /usr/share/kde4/config) , the configuration file is a xml and look like:


 <kdehome>/home/igor/kde/installs/trunk </kdehome>
 <item location="/path/to/file.vcf"


After that you only needs to run the testrunner:


and it creates a shell script file in your current directory called testenvironment.sh and you just need to run it.

%source testenvironment.sh

And right now you have a self contained Akonadi server.

KNUT Test Data Resource

In kdepim/akonadi/resources, fully featured resource that operates on a single XML file. File format is decribed in knut.xsd and follows closely the internal structure of Akonadi. New files can be created in eg. Akonadiconsole by creating a resource and specifying a non-existing file.

Akonadi Scriptable Resource

Second part of Igor's GSoC project, currently in playground/pim/akonaditest.


Akonadi Benchmarker

In kdepimlibs/akonadi/test, part of Robert's thesis.



Akonadi Server

Usable without installation, run with ctest/make test as usual.


Better coverage than the above, but require special setup that destroys the data of the database of the regular Akonadi server instance.

  • test data from kdesupport/akonadi/server/src/storage needs to be applied before every run, using the make-unittest-mysql-embedded.sh script
  • add the following symlinks:
    • ~/.config/akonadi -> ~/.kde-unit-test/xdg/config
    • ~/.local/share/akonadi -> ~/.kde-unit-test/xdg/local/share

This needs porting to the Akonadi Testrunner, to avoid the aforementioned setup.


Are there any? TODO

Content is available under Creative Commons License SA 4.0 unless otherwise noted.