Exemple #1
0
        public void TestMainMethods()
        {
            _client.WithPaging(5);
            Assert.IsTrue(_client.Grid.EnablePaging);
            Assert.AreEqual(_client.Grid.Pager.PageSize, 5);
            Assert.AreEqual(_client.Grid.ServerAPI, ServerAPI.ItemsDTO);

            _client.WithMultipleFilters();
            Assert.IsTrue(_client.Grid.ComponentOptions.AllowMultipleFilters);

            _client.Searchable();
            Assert.IsTrue(_client.Grid.SearchingEnabled);
            Assert.IsTrue(_client.Grid.SearchingOnlyTextColumns);

            _client.Named("test");
            Assert.AreEqual(_client.Grid.ComponentOptions.GridName, "test");

            _client.Selectable(true);
            Assert.IsTrue(_client.Grid.ComponentOptions.Selectable);

            _client.ChangePageSize(true);
            Assert.IsTrue(_client.Grid.Pager.ChangePageSize);

            _client.ClearFiltersButton(true);
            Assert.IsTrue(_client.Grid.ClearFiltersButtonEnabled);

            _client.ExtSortable(true);
            Assert.IsTrue(_client.Grid.ExtSortingEnabled);

            _client.Groupable(false);
            Assert.IsFalse(_client.Grid.ExtSortingEnabled);
            Assert.IsFalse(_client.Grid.GroupingEnabled);
        }
Exemple #2
0
        public void TestMainMethods()
        {
            _client.WithPaging(5);
            Assert.IsTrue(_client.Grid.EnablePaging);
            Assert.AreEqual(_client.Grid.Pager.PageSize, 5);

            _client.WithMultipleFilters();
            Assert.IsTrue(_client.Grid.ComponentOptions.AllowMultipleFilters);

            _client.Named("test");
            Assert.AreEqual(_client.Grid.ComponentOptions.GridName, "test");

            _client.Selectable(true);
            Assert.IsTrue(_client.Grid.ComponentOptions.Selectable);
        }