Author: pekka.klarck
Date: Sun Mar 22 09:18:19 2009
New Revision: 1470

Modified:
   trunk/src/robot/parsing/model.py

Log:
removed a warning if a suite has same test case twice (issue 133)

Modified: trunk/src/robot/parsing/model.py
==============================================================================
--- trunk/src/robot/parsing/model.py    (original)
+++ trunk/src/robot/parsing/model.py    Sun Mar 22 09:18:19 2009
@@ -70,7 +70,7 @@
         syslog.info("Parsing test case file '%s'" % path)
         rawdata = self._get_rawdata(path, syslog)
         _BaseSuite.__init__(self, rawdata)
-        self.tests = self._process_testcases(rawdata, syslog)
+        self.tests = self._process_testcases(rawdata)

     def _get_source(self, path):
         return path
@@ -81,22 +81,13 @@
             return rawdata
raise DataError("Test case file '%s' contains no test cases." % path)

-    def _process_testcases(self, rawdata, syslog):
-        names = []
+    def _process_testcases(self, rawdata):
         tests = []
         for rawtest in rawdata.testcases:
             try:
-                test = TestCase(rawtest)
+                tests.append(TestCase(rawtest))
             except:
                 rawtest.report_invalid_syntax()
-                continue
-            tests.append(test)
-            name = utils.normalize(test.name)
-            if name in names:
- msg = "Multiple test cases with name '%s' in test suite '%s'"
-                syslog.warn(msg % (test.name, self.name))
-            else:
-                names.append(name)
         return tests


Reply via email to