Add test for query interface