PackageKit is quite a complicated code base. As with all my projects, there is a substantial self check framework that’s designed to catch bugs and regressions before we push releases. This was something enforced by my previous employer, but I’m sure it’s a good idea for any non-trivial code base, and it’s something I’ll continue to do.
The number of tests currently:
daemon: 216
libpackagekit: 202
gnome-packagekit: 75
The tests are all injecting valid and invalid input and then testing if the code does the right thing. This works really well for the daemon and the library, but does not work well for the GUI applications that need a full GUI framework.
I’ve tried dogtail, but I’m finding it hard to use, and really wanted something I could integrate with my existing system in C. Do any of you hackers recommend anything in particular or should I persist with dogtail? So far it’s looking best of the bunch.
You my have better luck with the newer (dogtail-inspired) Strongwind:
http://medsphere.org/community/project/strongwind
We use it extensively on the mono-a11y team.
Perhaps ldtp can be useful?
Are you doing any code coverage analysis? I find it’s very useful for checking that you’re really testing everything you think you are. I’ve actually had bugs that were masked because the code wasn’t testing everything that I thought it was.
I wrote a bit recently about testing one of my own projects:
http://c-algorithms.sourceforge.net/testing.html
Wow, I wrote that really badly. “I’ve actually had bugs that were masked because the code wasn’t testing everything that I thought it was.” should actually read “I’ve actually had bugs that were masked because the tests weren’t exercising all of the code that I thought they were”.
PackageKit for windows… any plan to put it on windows. It could be integrated with open source programs and we could update them through there, life could be sweet :)
‘Hard to use’ in what way? Ping me and I’ll see if I can help.