Author: janne.t.harkonen
Date: Wed Mar 25 03:56:36 2009
New Revision: 1527

Modified:
   trunk/atest/robot/parsing/caching_libs_and_resources.html
   trunk/src/robot/output/monitor.py
   trunk/src/robot/output/output.py

Log:
Merge branch 'syslog'

Modified: trunk/atest/robot/parsing/caching_libs_and_resources.html
==============================================================================
--- trunk/atest/robot/parsing/caching_libs_and_resources.html   (original)
+++ trunk/atest/robot/parsing/caching_libs_and_resources.html Wed Mar 25 03:56:36 2009
@@ -395,7 +395,7 @@
 <tr>
 <td></td>
 <td>Syslog File Should Contain In Order</td>
-<td>Tests executed successfully.</td>
+<td>Tests execution ended.</td>
 <td></td>
 <td></td>
 </tr>
@@ -622,4 +622,4 @@
 </tr>
 </tbody></table>

-</body></html>
\ No newline at end of file
+</body></html>

Modified: trunk/src/robot/output/monitor.py
==============================================================================
--- trunk/src/robot/output/monitor.py   (original)
+++ trunk/src/robot/output/monitor.py   Wed Mar 25 03:56:36 2009
@@ -30,20 +30,21 @@
     def __init__(self, width=78, colors=True):
         self.width = width
         self.colors = colors
-        self._started = False
+        self._running_suites = 0

     def start_suite(self, suite):
-        if not self._started:
+        if not self._running_suites:
             self._write_separator('=')
-        self._started = True
         self._write_info(suite.longname, suite.doc, start_suite=True)
         self._write_separator('=')
+        self._running_suites += 1

     def end_suite(self, suite):
         self._write_info(suite.longname, suite.doc)
         self._write_status(suite.status)
         self._write_message(suite.get_full_message())
         self._write_separator('=')
+        self._running_suites -= 1

     def start_test(self, test):
         self._write_info(test.name, test.doc)
@@ -55,7 +56,8 @@

     def output_file(self, name, path):
         # called by SYSLOG
-        self._write('%s %s' % ((name+':').ljust(8), utils.cygpath(path)))
+        if not self._running_suites:  # ignores splitted output files
+ self._write('%s %s' % ((name+':').ljust(8), utils.cygpath(path)))

     def write(self, msg, level):
         # called by SYSLOG

Modified: trunk/src/robot/output/output.py
==============================================================================
--- trunk/src/robot/output/output.py    (original)
+++ trunk/src/robot/output/output.py    Wed Mar 25 03:56:36 2009
@@ -82,6 +82,7 @@
     def end_suite(self, suite):
         outpath = self.logger.end_suite(suite)
         if outpath is not None:
+            SYSLOG.output_file('Output', outpath)
             orig_outpath = self._settings['Output']
suite.namespace.variables.set_global('${OUTPUT_FILE}', orig_outpath)
             self._create_split_log(outpath, suite)

Reply via email to