Index: test/gtest_xml_test_utils.py |
=================================================================== |
--- test/gtest_xml_test_utils.py (revision 586) |
+++ test/gtest_xml_test_utils.py (working copy) |
@@ -151,6 +151,8 @@ |
* The "time" attribute of <testsuites>, <testsuite> and <testcase> |
elements is replaced with a single asterisk, if it contains |
only digit characters. |
+ * The "datetime" attribute of <testsuites> elements is replaced with a single asterisk, if it contains |
+ a valid ISO8601 datetime value |
* The "type_param" attribute of <testcase> elements is replaced with a |
single asterisk (if it sn non-empty) as it is the type name returned |
by the compiler and is platform dependent. |
@@ -159,7 +161,10 @@ |
* The directory names in file paths are removed. |
* The stack traces are removed. |
""" |
- |
+ |
+ if element.tagName == "testsuites": |
+ datetime = element.getAttributeNode("datetime") |
+ datetime.value = re.sub(r"^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}$", "*", datetime.value) |
if element.tagName in ("testsuites", "testsuite", "testcase"): |
time = element.getAttributeNode("time") |
time.value = re.sub(r"^\d+(\.\d+)?$", "*", time.value) |