Index: trunk/test/unit/org/openstreetmap/josm/gui/tagging/presets/TaggingPresetSelectorTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/gui/tagging/presets/TaggingPresetSelectorTest.java	(revision 18821)
+++ trunk/test/unit/org/openstreetmap/josm/gui/tagging/presets/TaggingPresetSelectorTest.java	(revision 18823)
@@ -2,13 +2,10 @@
 package org.openstreetmap.josm.gui.tagging.presets;
 
-import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertSame;
 import static org.junit.jupiter.api.Assertions.assertTrue;
 
-import org.junit.jupiter.api.extension.RegisterExtension;
+import java.util.Collections;
+
 import org.junit.jupiter.api.Test;
-import org.openstreetmap.josm.gui.tagging.presets.TaggingPresetSelector.PresetClassification;
-import org.openstreetmap.josm.testutils.JOSMTestRules;
-
-import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
 
 /**
@@ -16,23 +13,19 @@
  */
 class TaggingPresetSelectorTest {
-
     /**
-     * Setup rule
-     */
-    @RegisterExtension
-    @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD")
-    public JOSMTestRules test = new JOSMTestRules();
-
-    /**
-     * Unit test for {@link PresetClassification#isMatching}.
+     * Unit test for {@link TaggingPresetSelector.PresetClassifications#getMatchingPresets}.
      */
     @Test
-    void testIsMatching() {
+    void testGetMatching() {
         TaggingPreset preset = new TaggingPreset();
         preset.name = "estação de bombeiros"; // fire_station in brazilian portuguese
-        PresetClassification pc = new PresetClassification(preset);
-        assertEquals(0, pc.isMatchingName("foo"));
-        assertTrue(pc.isMatchingName("estação") > 0);
-        assertTrue(pc.isMatchingName("estacao") > 0);
+        TaggingPresetSelector.PresetClassifications presetClassifications = new TaggingPresetSelector.PresetClassifications();
+        presetClassifications.loadPresets(Collections.singleton(preset));
+        assertTrue(presetClassifications.getMatchingPresets(null, new String[] {"foo"}, false,
+                false, null, null).isEmpty());
+        assertSame(preset, presetClassifications.getMatchingPresets(null, new String[] {"estação"}, false,
+                false, null, null).get(0).preset);
+        assertSame(preset, presetClassifications.getMatchingPresets(null, new String[] {"estacao"}, false,
+                false, null, null).get(0).preset);
     }
 }
