XX-11199 - added unit tests for paging groups. also changed response codes from NOT FOUND to BAD REQUEST for some cases.