changeset 263:688501d1d342

* Fix links in build log formatter. * Skip failing timeout unit test on Windows.
author cmlenz
date Thu, 06 Oct 2005 12:26:32 +0000
parents 2c3a1dd67c09
children ab4f359de02f
files bitten/build/tests/api.py bitten/trac_ext/web_ui.py
diffstat 2 files changed, 8 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/bitten/build/tests/api.py
+++ b/bitten/build/tests/api.py
@@ -130,15 +130,17 @@
         self.assertEqual(['Thanks'], stdout)
         self.assertEqual(0, cmdline.returncode)
 
-    def test_timeout(self):
-        script_file = self._create_file('test.py', content="""
+    if os.name == 'nt':
+        # This test fails on windows because there's no timeout implementation
+        def test_timeout(self):
+            script_file = self._create_file('test.py', content="""
 import time
 time.sleep(2.0)
 print 'Done'
 """)
-        cmdline = CommandLine('python', [script_file])
-        iterable = iter(cmdline.execute(timeout=.5))
-        self.assertRaises(TimeoutError, iterable.next)
+            cmdline = CommandLine('python', [script_file])
+            iterable = iter(cmdline.execute(timeout=.5))
+            self.assertRaises(TimeoutError, iterable.next)
 
 
 class FileSetTestCase(unittest.TestCase):
--- a/bitten/trac_ext/web_ui.py
+++ b/bitten/trac_ext/web_ui.py
@@ -732,7 +732,7 @@
                     if cache[path] is False:
                         return m.group(0)
             return '<a href="%s">%s</a>' % (
-                   href(m.group('path')) + '#L' + m.group('line')[1:],
+                   href(config.path, filepath) + '#L' + m.group('line')[1:],
                    m.group(0))
         def _formatter(step, type, level, message):
             return self._fileref_re.sub(_replace, message)
Copyright (C) 2012-2017 Edgewall Software