コード例 #1
0
        public void TestColumnRenderFunction()
        {
            GridColumnsBuilder factory = new GridColumnsBuilder();

            factory.Render(() => "onRender");
            var j = factory.ToJToken();

            Assert.Equal("{\"render\":function(d,t,r,m){return onRender(d,t,r,m);}}", j.ToString(Newtonsoft.Json.Formatting.None));
        }
コード例 #2
0
        public void TestColumnRenderNull()
        {
            GridColumnsBuilder factory = new GridColumnsBuilder();

            factory.Render((string)null);
            var j = factory.ToJToken();

            Assert.Equal("{\"render\":null}", j.ToString(Newtonsoft.Json.Formatting.None));
        }