add test logic to KnnModel