ProfileAPI_Scope: Use consistent message if Scope > 64 characters

Found in

EPiServer.Profiles.Client 1.7.0

Fixed in

EPiServer.Profiles.Client 1.8.0

Created

Nov 21, 2018

Updated

May 03, 2019

State

Closed, Fixed and tested


Description

Steps to reproduce

Create a new Scope with a scopeId of more than 64 characters, or create a trackevent/ profile/ segment/ blacklist or update profile/ segment with scope of more than 64 characters
For example, create a new scope:

 api/v1.0/scopes/2vhn1z8w40u95769802vhn1z8w40u95769802vhn1z8w40u95769802vhn1z8w40u9576980

Expected:
Returns an error message that is consistent with the error message in profileId and segment Id.
The error message in profile/ segment: Invalid profile/ segment Id. Profile/ Segment Id cannot be longer than 64 characters.
+ creating scope: expected message is "Invalid scope Id. Scope Id cannot be longer than 64 characters "
+ creating trackevent/ profile/ segment/ blacklist and update profile/ segment : expected message is "Invalid scope. Scope cannot be longer than 64 characters"

Actual: returns message:
+ creating scope: ScopeId maximum length is 64 characters.
+ creating trackevent/ profile/ segment/ blacklist and update profile/ segment: Scope maximum length is 64 characters.