Adding a few helper functions that are needed to add some more functionality to the tests. 3/4 should eventually move into evemu, and we can ifdef this code out if evemu's shipped version supports this functionality. 4/4 still feels clumsy, but I have to find a better approach to this yet. Cheers, Peter