Added RestTestHelpers to avoid same code duplicity. few tests refactored to use this.