Skip to content

Commit

Permalink
Client error exception tests refactored to pass after the constructor…
Browse files Browse the repository at this point in the history
… changes
  • Loading branch information
jlahteen committed Apr 16, 2019
1 parent e48133c commit 0ed47e5
Show file tree
Hide file tree
Showing 19 changed files with 57 additions and 57 deletions.
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_BadRequestException10_ShouldReturn()

try
{
throw new BadRequestException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new BadRequestException(ErrorCode.InvalidOrderNumber, "BadRequestExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (BadRequestException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_BadRequestException10_ShouldReturn()
HttpStatusCode.BadRequest,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"BadRequestExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_ConflictException10_ShouldReturn()

try
{
throw new ConflictException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new ConflictException(ErrorCode.InvalidOrderNumber, "ConflictExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (ConflictException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_ConflictException10_ShouldReturn()
HttpStatusCode.Conflict,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"ConflictExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_ExpectationFailedException10_ShouldReturn()

try
{
throw new ExpectationFailedException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new ExpectationFailedException(ErrorCode.InvalidOrderNumber, "ExpectationFailedExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (ExpectationFailedException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_ExpectationFailedException10_ShouldReturn()
HttpStatusCode.ExpectationFailed,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"ExpectationFailedExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_ForbiddenException10_ShouldReturn()

try
{
throw new ForbiddenException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new ForbiddenException(ErrorCode.InvalidOrderNumber, "ForbiddenExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (ForbiddenException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_ForbiddenException10_ShouldReturn()
HttpStatusCode.Forbidden,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"ForbiddenExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_GoneException10_ShouldReturn()

try
{
throw new GoneException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new GoneException(ErrorCode.InvalidOrderNumber, "GoneExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (GoneException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_GoneException10_ShouldReturn()
HttpStatusCode.Gone,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"GoneExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_LengthRequiredException10_ShouldReturn()

try
{
throw new LengthRequiredException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new LengthRequiredException(ErrorCode.InvalidOrderNumber, "LengthRequiredExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (LengthRequiredException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_LengthRequiredException10_ShouldReturn()
HttpStatusCode.LengthRequired,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"LengthRequiredExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_MethodNotAllowedException10_ShouldReturn()

try
{
throw new MethodNotAllowedException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new MethodNotAllowedException(ErrorCode.InvalidOrderNumber, "MethodNotAllowedExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (MethodNotAllowedException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_MethodNotAllowedException10_ShouldReturn()
HttpStatusCode.MethodNotAllowed,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"MethodNotAllowedExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_NotAcceptableException10_ShouldReturn()

try
{
throw new NotAcceptableException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new NotAcceptableException(ErrorCode.InvalidOrderNumber, "NotAcceptableExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (NotAcceptableException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_NotAcceptableException10_ShouldReturn()
HttpStatusCode.NotAcceptable,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"NotAcceptableExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_NotFoundException10_ShouldReturn()

try
{
throw new NotFoundException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new NotFoundException(ErrorCode.InvalidOrderNumber, "NotFoundExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (NotFoundException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_NotFoundException10_ShouldReturn()
HttpStatusCode.NotFound,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"NotFoundExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_PaymentRequiredException10_ShouldReturn()

try
{
throw new PaymentRequiredException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new PaymentRequiredException(ErrorCode.InvalidOrderNumber, "PaymentRequiredExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (PaymentRequiredException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_PaymentRequiredException10_ShouldReturn()
HttpStatusCode.PaymentRequired,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"PaymentRequiredExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_PreconditionFailedException10_ShouldReturn()

try
{
throw new PreconditionFailedException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new PreconditionFailedException(ErrorCode.InvalidOrderNumber, "PreconditionFailedExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (PreconditionFailedException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_PreconditionFailedException10_ShouldReturn()
HttpStatusCode.PreconditionFailed,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"PreconditionFailedExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_ProxyAuthenticationRequiredException10_ShouldRetur

try
{
throw new ProxyAuthenticationRequiredException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new ProxyAuthenticationRequiredException(ErrorCode.InvalidOrderNumber, "ProxyAuthenticationRequiredExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (ProxyAuthenticationRequiredException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_ProxyAuthenticationRequiredException10_ShouldRetur
HttpStatusCode.ProxyAuthenticationRequired,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"ProxyAuthenticationRequiredExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_RequestEntityTooLargeException10_ShouldReturn()

try
{
throw new RequestEntityTooLargeException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new RequestEntityTooLargeException(ErrorCode.InvalidOrderNumber, "RequestEntityTooLargeExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (RequestEntityTooLargeException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_RequestEntityTooLargeException10_ShouldReturn()
HttpStatusCode.RequestEntityTooLarge,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"RequestEntityTooLargeExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_RequestTimeoutException10_ShouldReturn()

try
{
throw new RequestTimeoutException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new RequestTimeoutException(ErrorCode.InvalidOrderNumber, "RequestTimeoutExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (RequestTimeoutException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_RequestTimeoutException10_ShouldReturn()
HttpStatusCode.RequestTimeout,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"RequestTimeoutExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_RequestUriTooLongException10_ShouldReturn()

try
{
throw new RequestUriTooLongException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new RequestUriTooLongException(ErrorCode.InvalidOrderNumber, "RequestUriTooLongExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (RequestUriTooLongException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_RequestUriTooLongException10_ShouldReturn()
HttpStatusCode.RequestUriTooLong,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"RequestUriTooLongExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_RequestedRangeNotSatisfiableException10_ShouldRetu

try
{
throw new RequestedRangeNotSatisfiableException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new RequestedRangeNotSatisfiableException(ErrorCode.InvalidOrderNumber, "RequestedRangeNotSatisfiableExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (RequestedRangeNotSatisfiableException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_RequestedRangeNotSatisfiableException10_ShouldRetu
HttpStatusCode.RequestedRangeNotSatisfiable,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"RequestedRangeNotSatisfiableExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down
Expand Up @@ -410,7 +410,7 @@ public void ThrowAndSerialize_UnauthorizedException10_ShouldReturn()

try
{
throw new UnauthorizedException(ErrorCode.InvalidOrderNumber, "The field content is not allowed at all. Please do better. At least check out the help URL!", "http://juhta.net/helpurls/1233333");
throw new UnauthorizedException(ErrorCode.InvalidOrderNumber, "UnauthorizedExceptionField", "The field content is not allowed at all. Please do better. At least check out the help URL!");
}

catch (UnauthorizedException ex)
Expand All @@ -421,8 +421,8 @@ public void ThrowAndSerialize_UnauthorizedException10_ShouldReturn()
HttpStatusCode.Unauthorized,
ErrorCode.InvalidOrderNumber.ToString(),
"The field content is not allowed at all. Please do better. At least check out the help URL!",
null,
"http://juhta.net/helpurls/1233333"
"UnauthorizedExceptionField",
null
);

clientErrorResponse1 = ex.ToClientErrorResponse();
Expand Down

0 comments on commit 0ed47e5

Please sign in to comment.