Make all tests work for query API

Minor updates required to make the tests conform to the test data.

Add missing methods to query API. All tests pass now.

Signed-off-by: Christoph Kassen <c.kassen@telekom.de>