[Zope-Checkins] CVS: Products/PluginIndexes/PathIndex/tests - testPathIndex.py:1.10.30.2

Florent Guillaume fg at nuxeo.com
Mon Aug 1 12:06:24 EDT 2005


Update of /cvs-repository/Products/PluginIndexes/PathIndex/tests
In directory cvs.zope.org:/tmp/cvs-serv6602

Modified Files:
      Tag: Zope-2_7-branch
	testPathIndex.py 
Log Message:
Merge from trunk (r37625):
Additional test. CMF requires this behaviour.



=== Products/PluginIndexes/PathIndex/tests/testPathIndex.py 1.10.30.1 => 1.10.30.2 ===
--- Products/PluginIndexes/PathIndex/tests/testPathIndex.py:1.10.30.1	Thu Sep 18 10:16:14 2003
+++ Products/PluginIndexes/PathIndex/tests/testPathIndex.py	Mon Aug  1 12:06:24 2005
@@ -201,6 +201,18 @@
             lst = list(res[0].keys())
             self.assertEqual(lst,results)
 
+    def testQueryPathReturnedInResult(self):
+
+        index = self._index
+        index.index_object(1, Dummy("/ff"))
+        index.index_object(2, Dummy("/ff/gg"))
+        index.index_object(3, Dummy("/ff/gg/3.html"))
+        index.index_object(4, Dummy("/ff/gg/4.html"))
+        res = index._apply_index({'path': {'query': '/ff/gg'}})
+        lst = list(res[0].keys())
+        self.assertEqual(lst, [2, 3, 4])
+
+
 def test_suite():
     return unittest.makeSuite( TestCase )
 



More information about the Zope-Checkins mailing list