Items per page:
$indexKeyValuePage Size
0 key_1_1 value 1 10
1 key_1_2 value 2 10
2 key_1_3 value 3 10
3 key_1_4 value 4 10
4 key_1_5 value 5 10
5 key_1_6 value 6 10
6 key_1_7 value 7 10
7 key_1_8 value 8 10
8 key_1_9 value 9 10
9 key_1_10 value 10 10
Page 1 of 100 1 2 3 4 5
1 of 100
Items per page:
$indexKeyValuePage Size
0 key_2_1 value 1 10
1 key_2_2 value 2 10
2 key_2_3 value 3 10
3 key_2_4 value 4 10
4 key_2_5 value 5 10
5 key_2_6 value 6 10
6 key_2_7 value 7 10
7 key_2_8 value 8 10
8 key_2_9 value 9 10
9 key_2_10 value 10 10
Page 1 of 100 1 2 3 4 5
1 of 100
Items per page:
$indexKeyValuePage Size
0 key_3_1 value 1 25
1 key_3_2 value 2 25
2 key_3_3 value 3 25
3 key_3_4 value 4 25
4 key_3_5 value 5 25
5 key_3_6 value 6 25
6 key_3_7 value 7 25
7 key_3_8 value 8 25
8 key_3_9 value 9 25
9 key_3_10 value 10 25
Page 1 of 100 1 2 3 4 5
1 of 100
Items per page:
$indexKeyValuePage Size
0 key_4_0 value 0 10
1 key_4_1 value 1 10
2 key_4_2 value 2 10
3 key_4_3 value 3 10
4 key_4_4 value 4 10
5 key_4_5 value 5 10
6 key_4_6 value 6 10
7 key_4_7 value 7 10
8 key_4_8 value 8 10
9 key_4_9 value 9 10
Page 1 of 10 1 2 3 4 5
1 of 10
Items per page:
$indexKeyValuePage Size
0 key_5_0 value 0 10
1 key_5_1 value 1 10
2 key_5_2 value 2 10
3 key_5_3 value 3 10
4 key_5_4 value 4 10
5 key_5_5 value 5 10
6 key_5_6 value 6 10
7 key_5_7 value 7 10
8 key_5_8 value 8 10
9 key_5_9 value 9 10
Page 1 of 10 1 2 3 4 5
1 of 10
Items per page:
$indexKeyValuePage Size
0 key_6_1 value 1 10
1 key_6_2 value 2 10
2 key_6_3 value 3 10
3 key_6_4 value 4 10
4 key_6_5 value 5 10
5 key_6_6 value 6 10
6 key_6_7 value 7 10
7 key_6_8 value 8 10
8 key_6_9 value 9 10
9 key_6_10 value 10 10
Page 1 of 100 1 2 3 4 5
1 of 100
Items per page:
$indexKeyValuePage Size
0 key_7_0 value 0 10
1 key_7_1 value 1 10
2 key_7_2 value 2 10
3 key_7_3 value 3 10
4 key_7_4 value 4 10
5 key_7_5 value 5 10
6 key_7_6 value 6 10
7 key_7_7 value 7 10
8 key_7_8 value 8 10
9 key_7_9 value 9 10
Page 1 of 20 1 2 3 4 5
1 of 20

Unit Tests

Tests completed in 97 milliseconds.
79 assertions of 79 passed, 0 failed.

  1. paging view model - base Pager - empty initializer: inital pages are empty (0, 1, 1)Rerun1 ms
    1. paged items
  2. paging view model - base Pager - empty initializer: inital page is 1 (0, 1, 1)Rerun0 ms
    1. page
  3. paging view model - base Pager - empty initializer: inital itemsPerPage is 10 (0, 1, 1)Rerun0 ms
    1. itemsPerPage
  4. paging view model - base Pager - empty initializer: inital allowChangePageSize is false (0, 1, 1)Rerun0 ms
    1. allowChangePageSize
  5. paging view model - base Pager - empty initializer: inital totalPages is 0 (0, 1, 1)Rerun1 ms
    1. totalPages
  6. paging view model - base Pager - empty initializer: inital relativePages are empty (0, 1, 1)Rerun0 ms
    1. relativePages
  7. paging view model - ClientPager - empty initializer: inital pages are empty (0, 1, 1)Rerun0 ms
    1. paged items
  8. paging view model - ClientPager - empty initializer: inital page is 1 (0, 1, 1)Rerun1 ms
    1. page
  9. paging view model - ClientPager - empty initializer: inital itemsPerPage is 10 (0, 1, 1)Rerun0 ms
    1. itemsPerPage
  10. paging view model - ClientPager - empty initializer: inital allowChangePageSize is false (0, 1, 1)Rerun0 ms
    1. allowChangePageSize
  11. paging view model - ClientPager - empty initializer: inital totalPages is 0 (0, 1, 1)Rerun0 ms
    1. totalPages
  12. paging view model - ClientPager - empty initializer: inital relativePages are empty (0, 1, 1)Rerun0 ms
    1. relativePages
  13. paging view model - ClientPager - updates to observableArray: pager updates with observableArray (0, 2, 2)Rerun1 ms
    1. paged items
    2. relativePages
  14. paging view model - ClientPager - updates to observableArray: page cannot go below 1 (0, 2, 2)Rerun0 ms
    1. page
    2. page
  15. paging view model - ClientPager - updates to observableArray: page cannot go past last page with single page of data (0, 2, 2)Rerun0 ms
    1. page
    2. page
  16. paging view model - ClientPager - updates to observableArray: relativePages only show available pages (0, 2, 2)Rerun1 ms
    1. relativePages
    2. relativePages
  17. paging view model - ClientPager - updates to observableArray: page cannot go past last page with multiple pages of data (0, 2, 2)Rerun0 ms
    1. page
    2. page
  18. paging view model - ClientPager - updates to observableArray: pager updates with observableArray and only displays one page (0, 2, 2)Rerun0 ms
    1. paged items
    2. relativePages
  19. paging view model - ClientPager - updates to observableArray: page can update with multiple pages of data (0, 2, 2)Rerun0 ms
    1. page
    2. page
  20. paging view model - ClientPager - updates to observableArray: changing the page updates the relativePages (0, 2, 2)Rerun0 ms
    1. relativePages
    2. relativePages
  21. paging view model - ServerPager - empty initializer: inital page is 1 (0, 1, 1)Rerun0 ms
    1. page
  22. paging view model - ServerPager - empty initializer: inital itemsPerPage is 10 (0, 1, 1)Rerun0 ms
    1. itemsPerPage
  23. paging view model - ServerPager - empty initializer: inital allowChangePageSize is false (0, 1, 1)Rerun0 ms
    1. allowChangePageSize
  24. paging view model - ServerPager - empty initializer: inital totalPages is 0 (0, 1, 1)Rerun0 ms
    1. totalPages
  25. paging view model - ServerPager - empty initializer: inital relativePages are empty (0, 1, 1)Rerun0 ms
    1. relativePages
  26. paging view model - ServerPager: totalItems updates (0, 1, 1)Rerun0 ms
    1. totalPages
  27. paging view model - ServerPager: server page method is called (0, 1, 1)Rerun0 ms
    1. getPageMethod
  28. paging view model - ServerPager: correct itemsPerPage is passed to page method (0, 2, 2)Rerun0 ms
    1. getPageMethod
    2. getPageMethod
  29. paging view model - ServerPager: pager calculates relativePages based on totalItems (0, 2, 2)Rerun0 ms
    1. relativePages
    2. relativePages
  30. pagingForeach binding - observableArray: pageSizeControl binding adds a select with 4 options (0, 2, 2)Rerun3 ms
    1. pageSizeControl
    2. pageSizeControl
  31. pagingForeach binding - observableArray: pageSize binding adds 25 rows (0, 1, 1)Rerun0 ms
    1. pageSize
  32. pagingForeach binding - observableArray: pageSize binding updates (0, 3, 3)Rerun7 ms
    1. pageSize
    2. pageSize
    3. pageSize
  33. pagingForeach binding - observableArray: pageLinks adds first page button (0, 1, 1)Rerun0 ms
    1. pageLinks
  34. pagingForeach binding - observableArray: pageLinks adds last page button (0, 1, 1)Rerun1 ms
    1. pageLinks
  35. pagingForeach binding - observableArray: pageLinks adds page number buttons (0, 1, 1)Rerun0 ms
    1. pageLinks
  36. pagingForeach binding - observableArray: first page button is disabled on page 1 (0, 1, 1)Rerun1 ms
    1. pageLinks
  37. pagingForeach binding - observableArray: first page button is not disabled on other pages (0, 1, 1)Rerun2 ms
    1. pageLinks
  38. pagingForeach binding - observableArray: last page button is disabled on last page (0, 1, 1)Rerun4 ms
    1. last page
  39. pagingForeach binding - observableArray: last page button is not disabled on other pages (0, 1, 1)Rerun5 ms
    1. last page
  40. pagingForeach binding - observableArray: $parent binding has correct scope (0, 2, 2)Rerun3 ms
    1. $parent
    2. $parent
  41. pagingForeach binding - static array: pageSizeControl binding adds a select with 4 options (0, 2, 2)Rerun0 ms
    1. pageSizeControl
    2. pageSizeControl
  42. pagingForeach binding - static array: pageSize binding adds 10 rows (0, 1, 1)Rerun0 ms
    1. pageSize
  43. pagingForeach binding - static array: pageSize binding updates (0, 3, 3)Rerun4 ms
    1. pageSize
    2. pageSize
    3. pageSize
  44. pagingForeach binding - static array: pageLinks adds first page button (0, 1, 1)Rerun0 ms
    1. pageLinks
  45. pagingForeach binding - static array: pageLinks adds last page button (0, 1, 1)Rerun1 ms
    1. pageLinks
  46. pagingForeach binding - static array: pageLinks adds page number buttons (0, 1, 1)Rerun0 ms
    1. pageLinks
  47. pagingForeach binding - static array: first page button is disabled on page 1 (0, 1, 1)Rerun0 ms
    1. pageLinks
  48. pagingForeach binding - static array: first page button is not disabled on other pages (0, 1, 1)Rerun4 ms
    1. pageLinks
  49. pagingForeach binding - static array: last page button is disabled on last page (0, 1, 1)Rerun2 ms
    1. last page
  50. pagingForeach binding - static array: last page button is not disabled on other pages (0, 1, 1)Rerun4 ms
    1. last page
  51. pagingForeach binding - static array: $parent binding has correct scope (0, 2, 2)Rerun3 ms
    1. $parent
    2. $parent
  52. pagingForeach binding - static pageSize: pageSize binding adds 25 rows (0, 1, 1)Rerun0 ms
    1. pageSize
  53. pagingForeach binding - static pageSize: user can still change page size (0, 1, 1)Rerun1 ms
    1. pageSize
  54. pagingForeach binding - serverMethod: pageSize binding adds 25 rows (0, 1, 1)Rerun1 ms
    1. pageSize
  55. pagingForeach binding - serverMethod: user can still change page size (0, 1, 1)Rerun3 ms
    1. pageSize
  56. pagingForeach binding - serverMethod: pageSize binding adds 25 rows (0, 1, 1)Rerun3 ms
    1. pageSize
  57. pagingForeach binding - serverMethod: user can still change page size (0, 1, 1)Rerun2 ms
    1. pageSize
  58. pagingForeach binding - All: pageSize binding adds All rows (0, 2, 2)Rerun0 ms
    1. pageSize options
    2. pageSize - All
  59. pagingForeach binding - All - serverMethod: pageSize binding adds All rows (0, 2, 2)Rerun0 ms
    1. pageSize options
    2. pageSize - All