added unit tests for restful services