public void GetData_ReturnsPublicJson()
        {
            datalist.GetData().Returns(new DatalistData());

            JsonResult actual       = controller.GetData(datalist, filter);
            Object     expectedData = datalist.GetData();

            Assert.Equal(JsonRequestBehavior.AllowGet, actual.JsonRequestBehavior);
            Assert.Same(expectedData, actual.Data);
        }
        public virtual JsonResult GetData(MvcDatalist datalist, DatalistFilter filter)
        {
            datalist.Filter = filter;

            return(Json(datalist.GetData(), JsonRequestBehavior.AllowGet));
        }