@Test
public void testCreateQueryWithWithinWhereUnitIsMiles() throws NoSuchMethodException, SecurityException {
Method method = SampleRepository.class.getMethod("findByLocationWithin", Point.class, Distance.class);
Query query = createQueryForMethodWithArgs(method, new Object[] { new Point(48.303056, 14.290556),
new Distance(1, Metrics.MILES) });
Assert.assertEquals("{!geofilt pt=48.303056,14.290556 sfield=store d=1.609344}", queryParser.getQueryString(query));
}