]> git.openstreetmap.org Git - nominatim.git/blobdiff - test/python/test_tokenizer_legacy.py
test: use table_rows() and execute_values() where possible
[nominatim.git] / test / python / test_tokenizer_legacy.py
index 76b51f717e93e8ca08de78433cdd3d31d15a8dad..5993562ac989fe100ee3f82ac77ff51bfc13021d 100644 (file)
@@ -247,11 +247,11 @@ def test_update_special_phrases_no_replace(analyzer, word_table, temp_db_cursor,
                               VALUES (' foo', 'foo', 'amenity', 'prison', 'in'),
                                      (' bar', 'bar', 'highway', 'road', null)""")
 
-    assert 2 == temp_db_cursor.scalar("SELECT count(*) FROM word WHERE class != 'place'""")
+    assert word_table.count_special() == 2
 
     analyzer.update_special_phrases([], False)
 
-    assert 2 == temp_db_cursor.scalar("SELECT count(*) FROM word WHERE class != 'place'""")
+    assert word_table.count_special() == 2
 
 
 def test_update_special_phrase_modify(analyzer, word_table, make_standard_name):