Exemplo n.º 1
0
        public void DiggPaginationComponent()
        {
            var            writer     = new StringWriter();
            IList <string> dataSource = new List <string>();

            for (int i = 100; i != 200; i++)
            {
                dataSource.Add(i.ToString());
            }

            controllerContext.PropertyBag["items"] = PaginationHelper.CreatePagination(dataSource, 10, 3);

            manager.Process("Home\\DiggPaginationComponent", writer, engineContext, controller, controllerContext);

            ContainsInOrder(writer.GetStringBuilder().ToString(),
                            "<li>130</li>", "<li>139</li>");
        }
Exemplo n.º 2
0
 public void ProcessBasicTemplate()
 {
     mocks.ReplayAll();
     manager.Process("Home\\Index", output, engineContext, controller, controllerContext);
     Assert.That(output.ToString().Contains("<h1>Simple test</h1>"));
 }