add tests for sidebar count and pagination