@Test
public void findTasksWithFieldFiltering() {

    Pair<List<Task>, List<Task>> cellSnapshots = generateTestJobsWithTasks();
    List<Task> allTasks = walkAllPages(
            6,
            request -> service.findTasks(request, UNDEFINED_CALL_METADATA),
            page -> TaskQuery.newBuilder()
                    .setPage(page)
                    .addFields("jobId")
                    .build(),
            TaskQueryResult::getPagination,
            TaskQueryResult::getItemsList
    );
    assertThat(allTasks).hasSize(cellSnapshots.getLeft().size() + cellSnapshots.getRight().size());
    for (Task task : allTasks) {
        assertThat(task.getId()).isNotEmpty();
        assertThat(task.getJobId()).isNotEmpty();
        assertThat(task.getStatus().getReasonMessage()).isEmpty();
        assertThat(task.getStatusHistoryList()).isEmpty();
    }
}