[Python-checkins] r88913 - in tracker/instances/python-dev/extensions: local_replace.py test/local_replace_data.txt test/test_local_replace.py

ezio.melotti python-checkins at python.org
Tue Oct 18 15:36:10 CEST 2011


Author: ezio.melotti
Date: Tue Oct 18 15:36:10 2011
New Revision: 88913

Log:
#407: fix linkification of hg changesets.

Modified:
   tracker/instances/python-dev/extensions/local_replace.py
   tracker/instances/python-dev/extensions/test/local_replace_data.txt
   tracker/instances/python-dev/extensions/test/test_local_replace.py

Modified: tracker/instances/python-dev/extensions/local_replace.py
==============================================================================
--- tracker/instances/python-dev/extensions/local_replace.py	(original)
+++ tracker/instances/python-dev/extensions/local_replace.py	Tue Oct 18 15:36:10 2011
@@ -74,9 +74,9 @@
 
 substitutions = [
     # deadbeeffeed  (hashes with exactly twelve or forty chars)
-    (re.compile(r'\b(?<![/?&;])(?P<revision>[a-fA-F0-9]{40})\b'),
+    (re.compile(r'\b(?<![/?&;=])(?P<revision>[a-fA-F0-9]{40})\b'),
      r'<a href="http://hg.python.org/lookup/\g<revision>">\g<revision></a>'),
-    (re.compile(r'\b(?<![/?&;])(?P<revision>[a-fA-F0-9]{12})\b'),
+    (re.compile(r'\b(?<![/?&;=])(?P<revision>[a-fA-F0-9]{12})\b'),
      r'<a href="http://hg.python.org/lookup/\g<revision>">\g<revision></a>'),
 
     # r12345, r 12345, rev12345, rev 12345, revision12345, revision 12345

Modified: tracker/instances/python-dev/extensions/test/local_replace_data.txt
==============================================================================
--- tracker/instances/python-dev/extensions/test/local_replace_data.txt	(original)
+++ tracker/instances/python-dev/extensions/test/local_replace_data.txt	Tue Oct 18 15:36:10 2011
@@ -21,6 +21,10 @@
 I uploaded http://pypi.python.org/pypi/ctypesgen/0.r125
 I uploaded <a href="http://pypi.python.org/pypi/ctypesgen/0.r125">http://pypi.python.org/pypi/ctypesgen/0.r125</a>
 ##
+## hg revisions
+http://code.google.com/p/spyderlib/source/detail?spec=svne5d86b685619a470d593aa5f9ee360ba60779bc1&r=323c6c697f045166e384cdc15803d40eebed0a2b
+<a href="http://code.google.com/p/spyderlib/source/detail?spec=svne5d86b685619a470d593aa5f9ee360ba60779bc1&amp;r=323c6c697f045166e384cdc15803d40eebed0a2b">http://code.google.com/p/spyderlib/source/detail?spec=svne5d86b685619a470d593aa5f9ee360ba60779bc1&amp;r=323c6c697f045166e384cdc15803d40eebed0a2b</a>
+##
 ## issues - the lowest issue id on bugs.python.org is #1000, the highest is #1779871
  #1
  #1

Modified: tracker/instances/python-dev/extensions/test/test_local_replace.py
==============================================================================
--- tracker/instances/python-dev/extensions/test/test_local_replace.py	(original)
+++ tracker/instances/python-dev/extensions/test/test_local_replace.py	Tue Oct 18 15:36:10 2011
@@ -47,6 +47,7 @@
 
 class TestPyDevStringHTMLProperty(TemplatingTestCase):
     def test_replacement(self):
+        self.maxDiff = None
         # create a db with a few issue/msg/file ids
         self.client.db = self._db = PyDevMockDatabase(
                 [1000, 5555, 555555, 1999999, 2000000, 1234567890123])


More information about the Python-checkins mailing list