This commit is contained in:
@@ -63,7 +63,7 @@ namespace raven_integration
|
||||
d.notes = "notes";
|
||||
d.customFields = Util.UserRequiredCustomFieldsJsonString();
|
||||
|
||||
a = await Util.PostAsync("User", await Util.GetTokenAsync("manager", "l3tm3in"), d.ToString());
|
||||
a = await Util.PostAsync("User", await Util.GetTokenAsync("superuser", "l3tm3in"), d.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
long InNameId = a.ObjectResponse["data"]["id"].Value<long>();
|
||||
|
||||
@@ -79,7 +79,7 @@ namespace raven_integration
|
||||
d.notes = "notes";
|
||||
d.customFields = Util.UserRequiredCustomFieldsJsonString();
|
||||
|
||||
a = await Util.PostAsync("User", await Util.GetTokenAsync("manager", "l3tm3in"), d.ToString());
|
||||
a = await Util.PostAsync("User", await Util.GetTokenAsync("superuser", "l3tm3in"), d.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
long InEmployeeNumberId = a.ObjectResponse["data"]["id"].Value<long>();
|
||||
|
||||
@@ -113,10 +113,10 @@ namespace raven_integration
|
||||
pickList[0]["id"].Value<long>().Should().Be(InNameId);
|
||||
|
||||
//DELETE TEST USERS NO LONGER NEEDED
|
||||
a = await Util.DeleteAsync("User/" + InNameId.ToString(), await Util.GetTokenAsync("manager", "l3tm3in"));
|
||||
a = await Util.DeleteAsync("User/" + InNameId.ToString(), await Util.GetTokenAsync("superuser", "l3tm3in"));
|
||||
Util.ValidateHTTPStatusCode(a, 204);
|
||||
|
||||
a = await Util.DeleteAsync("User/" + InEmployeeNumberId.ToString(), await Util.GetTokenAsync("manager", "l3tm3in"));
|
||||
a = await Util.DeleteAsync("User/" + InEmployeeNumberId.ToString(), await Util.GetTokenAsync("superuser", "l3tm3in"));
|
||||
Util.ValidateHTTPStatusCode(a, 204);
|
||||
|
||||
|
||||
@@ -257,7 +257,7 @@ namespace raven_integration
|
||||
[Fact]
|
||||
public async void FetchWidgetPickListPreDefined()
|
||||
{
|
||||
//fetch the manager account which always exists
|
||||
//fetch the SuperUser account which always exists
|
||||
ApiResponse a = await Util.GetAsync("pick-list/list?ayaType=3&preId=1", await Util.GetTokenAsync("BizAdminFull"));
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
//assert contains 1 record
|
||||
@@ -289,7 +289,7 @@ namespace raven_integration
|
||||
w.usertype = 1;
|
||||
w.dollarAmount = 555.55;
|
||||
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync("manager", "l3tm3in"), w.ToString());
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync("superuser", "l3tm3in"), w.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
IncludedWidgetId = a.ObjectResponse["data"]["id"].Value<long>();
|
||||
|
||||
@@ -333,7 +333,7 @@ namespace raven_integration
|
||||
InclusiveTagsArray.Add("plblue");
|
||||
w.tags = InclusiveTagsArray;
|
||||
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync("manager", "l3tm3in"), w.ToString());
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync("superuser", "l3tm3in"), w.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
IncludedWidgetId = a.ObjectResponse["data"]["id"].Value<long>();
|
||||
|
||||
@@ -376,14 +376,14 @@ namespace raven_integration
|
||||
w.active = true;
|
||||
w.usertype = 1;
|
||||
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync("manager", "l3tm3in"), w.ToString());
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync("superuser", "l3tm3in"), w.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
ActiveWidgetIdList.Add(a.ObjectResponse["data"]["id"].Value<long>());
|
||||
|
||||
//second active widget
|
||||
w.name = Util.Uniquify(WidgetNameStart);
|
||||
|
||||
a = await Util.PostAsync("widget", await Util.GetTokenAsync("manager", "l3tm3in"), w.ToString());
|
||||
a = await Util.PostAsync("widget", await Util.GetTokenAsync("superuser", "l3tm3in"), w.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
ActiveWidgetIdList.Add(a.ObjectResponse["data"]["id"].Value<long>());
|
||||
|
||||
@@ -392,7 +392,7 @@ namespace raven_integration
|
||||
w.name = Util.Uniquify(WidgetNameStart);
|
||||
w.active = false;
|
||||
|
||||
a = await Util.PostAsync("widget", await Util.GetTokenAsync("manager", "l3tm3in"), w.ToString());
|
||||
a = await Util.PostAsync("widget", await Util.GetTokenAsync("superuser", "l3tm3in"), w.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
NotActiveWidgetIdList.Add(a.ObjectResponse["data"]["id"].Value<long>());
|
||||
|
||||
@@ -400,7 +400,7 @@ namespace raven_integration
|
||||
w.name = Util.Uniquify(WidgetNameStart);
|
||||
w.active = false;
|
||||
|
||||
a = await Util.PostAsync("widget", await Util.GetTokenAsync("manager", "l3tm3in"), w.ToString());
|
||||
a = await Util.PostAsync("widget", await Util.GetTokenAsync("superuser", "l3tm3in"), w.ToString());
|
||||
Util.ValidateDataReturnResponseOk(a);
|
||||
NotActiveWidgetIdList.Add(a.ObjectResponse["data"]["id"].Value<long>());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user