mirror of
https://github.com/qgis/QGIS.git
synced 2025-03-12 00:02:25 -04:00
Added case insensitive filter prefix checks
This commit is contained in:
parent
0340aad702
commit
b6479c65ae
@ -226,6 +226,11 @@ class TestQgsLocator(unittest.TestCase):
|
||||
QCoreApplication.processEvents()
|
||||
self.assertEqual(got_hit._results_, [])
|
||||
got_hit._results_ = []
|
||||
l.fetchResults('AaA a', context)
|
||||
for i in range(100):
|
||||
sleep(0.002)
|
||||
QCoreApplication.processEvents()
|
||||
self.assertEqual(set(got_hit._results_), {'a0', 'a1', 'a2'})
|
||||
|
||||
# test with two filters
|
||||
filter_b = test_filter('b', 'bbb')
|
||||
@ -278,6 +283,13 @@ class TestQgsLocator(unittest.TestCase):
|
||||
sleep(0.002)
|
||||
QCoreApplication.processEvents()
|
||||
self.assertEqual(set(got_hit._results_), {'custom0', 'custom1', 'custom2'})
|
||||
filter_c.setUseWithoutPrefix(False)
|
||||
got_hit._results_ = []
|
||||
l.fetchResults('XyZ b', context)
|
||||
for i in range(100):
|
||||
sleep(0.002)
|
||||
QCoreApplication.processEvents()
|
||||
self.assertEqual(set(got_hit._results_), {'custom0', 'custom1', 'custom2'})
|
||||
l.deregisterFilter(filter_c)
|
||||
|
||||
del l
|
||||
|
Loading…
x
Reference in New Issue
Block a user