move all tests to query