This commit is contained in:
2020-03-17 23:32:46 +00:00
parent ef01470d13
commit af35225281

View File

@@ -148,6 +148,24 @@ namespace raven_integration
templateList[0]["id"].Value<long>().Should().Be(2);//first one should be a widget
}
/// <summary>
/// test get picklist fields list
/// </summary>
[Fact]
public async void TemplateFieldList()
{
//RETRIEVE WIDGET PICKLIST FIELDS
ApiResponse a = await Util.GetAsync("PickList/Template/ListFields/2", await Util.GetTokenAsync("BizAdminFull"));
Util.ValidateDataReturnResponseOk(a);
//assert contains at least two records (as we only have two at time of writing this test)
var templateList = ((JArray)a.ObjectResponse["data"]);
templateList.Count.Should().BeGreaterThan(4);
templateList[0]["fieldKey"].Value<string>().Should().Be("widgetactive");//first one should be a widgetactive field
}
// /// <summary>
// ///
// /// </summary>