This commit is contained in:
@@ -11,27 +11,27 @@ namespace raven_integration
|
||||
{
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Test business rule should be active on new
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public async void BusinessRuleNewShouldBeActiveShouldWork()
|
||||
{
|
||||
//CREATE attempt with broken rules
|
||||
dynamic d = new JObject();
|
||||
d.name = Util.Uniquify("ServerShouldDisAllowOwnerOnlyRightsUserToDeleteNonOwned TEST WIDGET");
|
||||
d.created = DateTime.Now.ToString();
|
||||
d.dollarAmount = 1.11m;
|
||||
d.active = false;//<--- BROKEN RULE new widget must be active = true!!
|
||||
d.roles = 0;
|
||||
// /// <summary>
|
||||
// /// Test business rule should be active on new
|
||||
// /// </summary>
|
||||
// [Fact]
|
||||
// public async void BusinessRuleNewShouldBeActiveShouldWork()
|
||||
// {
|
||||
// //CREATE attempt with broken rules
|
||||
// dynamic d = new JObject();
|
||||
// d.name = Util.Uniquify("ServerShouldDisAllowOwnerOnlyRightsUserToDeleteNonOwned TEST WIDGET");
|
||||
// d.created = DateTime.Now.ToString();
|
||||
// d.dollarAmount = 1.11m;
|
||||
// d.active = false;//<--- BROKEN RULE new widget must be active = true!!
|
||||
// d.roles = 0;
|
||||
|
||||
//create via inventory full test user
|
||||
ApiResponse a = await Util.PostAsync("Widget", await Util.GetTokenAsync("InventoryFull"), d.ToString());
|
||||
// //create via inventory full test user
|
||||
// ApiResponse a = await Util.PostAsync("Widget", await Util.GetTokenAsync("InventoryFull"), d.ToString());
|
||||
|
||||
Util.ValidateErrorCodeResponse(a, 2200, 400);
|
||||
Util.ShouldContainValidationError(a, "Active", "InvalidValue");
|
||||
// Util.ValidateErrorCodeResponse(a, 2200, 400);
|
||||
// Util.ShouldContainValidationError(a, "Active", "InvalidValue");
|
||||
|
||||
}
|
||||
// }
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user