sorted out my mess and added a unit test for the rest service.
more experiments with tests