2 new revisions:
Revision: 159febb80f14
Branch: default
Author: Pekka Klärck
Date: Sun May 26 04:12:33 2013
Log: new run: criticality
http://code.google.com/p/robotframework/source/detail?r=159febb80f14
Revision: da9545a7d808
Branch: default
Author: Pekka Klärck
Date: Sun May 26 05:27:16 2013
Log: new run: randomizing suites/tests
http://code.google.com/p/robotframework/source/detail?r=da9545a7d808
==============================================================================
Revision: 159febb80f14
Branch: default
Author: Pekka Klärck
Date: Sun May 26 04:12:33 2013
Log: new run: criticality
http://code.google.com/p/robotframework/source/detail?r=159febb80f14
Modified:
/src/robot/model/criticality.py
/src/robot/new_running/runner.py
=======================================
--- /src/robot/model/criticality.py Fri May 17 03:22:02 2013
+++ /src/robot/model/criticality.py Sun May 26 04:12:33 2013
@@ -18,8 +18,11 @@
class Criticality(object):
def __init__(self, critical_tags=None, non_critical_tags=None):
- self.critical_tags = TagPatterns(critical_tags)
- self.non_critical_tags = TagPatterns(non_critical_tags)
+ self.critical_tags = self._get_tag_patterns(critical_tags)
+ self.non_critical_tags = self._get_tag_patterns(non_critical_tags)
+
+ def _get_tag_patterns(self, tags):
+ return TagPatterns(tags) if not isinstance(tags, TagPatterns) else
tags
def tag_is_critical(self, tag):
return self.critical_tags.match(tag)
@@ -38,4 +41,3 @@
# TODO: Remove compatibility with old Statistics
is_critical = tag_is_critical
is_non_critical = tag_is_non_critical
-
=======================================
--- /src/robot/new_running/runner.py Sun May 26 03:29:36 2013
+++ /src/robot/new_running/runner.py Sun May 26 04:12:33 2013
@@ -58,6 +58,8 @@
source=suite.source,
starttime=utils.get_timestamp())
if not self.result:
+ result.set_criticality(suite.criticality.critical_tags,
+ suite.criticality.non_critical_tags)
self.result = Result(root_suite=result)
else:
self._suite.suites.append(result)
==============================================================================
Revision: da9545a7d808
Branch: default
Author: Pekka Klärck
Date: Sun May 26 05:27:16 2013
Log: new run: randomizing suites/tests
http://code.google.com/p/robotframework/source/detail?r=da9545a7d808
Modified:
/src/robot/conf/settings.py
/src/robot/new_running/model.py
=======================================
--- /src/robot/conf/settings.py Wed May 22 04:57:27 2013
+++ /src/robot/conf/settings.py Sun May 26 05:27:16 2013
@@ -109,7 +109,7 @@
return [self._process_tag_stat_combine(v) for v in value]
if name == 'TagStatLink':
return [v for v in [self._process_tag_stat_link(v) for v in
value] if v]
- if name == 'RemoveKeywords':
+ if name in ['RemoveKeywords', 'RunMode']:
return [v.upper() for v in value]
return value
@@ -332,8 +332,18 @@
'include_tests': self['TestNames'],
'empty_suite_ok': self['RunEmptySuite'],
'critical': self['Critical'],
- 'non_critical': self['NonCritical']
+ 'non_critical': self['NonCritical'],
+ 'randomize_suites': self.randomize_suites,
+ 'randomize_tests': self.randomize_tests
}
+
+ @property
+ def randomize_suites(self):
+ return any(mode in ('RANDOM:SUITE', 'RANDOM:ALL') for mode in
self['RunMode'])
+
+ @property
+ def randomize_tests(self):
+ return any(mode in ('RANDOM:TEST', 'RANDOM:ALL') for mode in
self['RunMode'])
class RebotSettings(_BaseSettings):
=======================================
--- /src/robot/new_running/model.py Sun May 26 02:31:26 2013
+++ /src/robot/new_running/model.py Sun May 26 05:27:16 2013
@@ -104,6 +104,11 @@
def variables(self, variables):
return model.ItemList(Variable, items=variables)
+ def configure(self, randomize_suites=False, randomize_tests=False,
+ **options):
+ model.TestSuite.configure(self, **options)
+ self.randomize(randomize_suites, randomize_tests)
+
def randomize(self, suites=True, tests=True):
self.visit(Randomizer(suites, tests))
--
---
You received this message because you are subscribed to the Google Groups "robotframework-commit" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.