Added test case to cover the query object as parameter