Range query in unit test