Only set query if page is specified. Tests for request
Test paging