public void select_data_source_url_with_source_type_and_a_query() { var targetGrid = new TargetGrid(); targetGrid.SourceIs <QueryGoodSource>(); targetGrid.DetermineRunnerType().ShouldEqual(typeof(GridRunner <GridDefTarget, TargetGrid, QueryGoodSource, DifferentClass>)); }
public void select_data_source_url_with_source_type_and_no_query() { var targetGrid = new TargetGrid(); targetGrid.SourceIs <SimpleGoodSource>(); targetGrid.DetermineRunnerType().ShouldEqual(typeof(GridRunner <GridDefTarget, TargetGrid, SimpleGoodSource>)); }
public void source_happy_path_with_query_object() { var targetGrid = new TargetGrid(); targetGrid.SourceIs <QueryGoodSource>(); targetGrid.SourceType.ShouldEqual(typeof(QueryGoodSource)); }
public void is_paged_true_with_paged_source() { var grid = new TargetGrid(); grid.SourceIs <PagedSource>(); grid.IsPaged().ShouldBeTrue(); }
public void is_paged_false_with_non_paged_source() { var grid = new TargetGrid(); grid.SourceIs <SimpleGoodSource>(); grid.IsPaged().ShouldBeFalse(); }
public void select_data_source_url_with_paged_source() { var targetGrid = new TargetGrid(); targetGrid.SourceIs <PagedSource>(); targetGrid.As <IGridDefinition>().DetermineRunnerType().ShouldEqual(typeof(PagedGridRunner <GridDefTarget, TargetGrid, PagedSource, SpecialPagedQuery>)); }