summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sandberg <andreas.sandberg@arm.com>2016-05-31 11:26:59 +0100
committerAndreas Sandberg <andreas.sandberg@arm.com>2016-05-31 11:26:59 +0100
commitdbf64aa2c2f803a659ed3cb8a128dbe1f73cfa06 (patch)
treee6dbee4c0521d8c75b60f8eb3f32ba353796c63f
parent62b6ff22ec1f90014b1d0fc778014bdb38cc09ce (diff)
downloadgem5-dbf64aa2c2f803a659ed3cb8a128dbe1f73cfa06.tar.xz
tests: Fix incorrect stat.txt ignore when updating refs
ClassicTest was incorrectly ignoring stats.txt when updating reference statistics. This was caused by ignore rules being applied too aggressively when listing reference files. This changeset splits the ignore rules into two different lists: 1) diff_ignore_files that lists the files that shouldn't be diff:ed using the normal diff tool, and 2) ref_ignore_files which lists files that should be ignored by the test system. Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
-rw-r--r--tests/testing/tests.py18
1 files changed, 13 insertions, 5 deletions
diff --git a/tests/testing/tests.py b/tests/testing/tests.py
index 4c467f25c..cf32e5c83 100644
--- a/tests/testing/tests.py
+++ b/tests/testing/tests.py
@@ -219,11 +219,19 @@ class Test(object):
return self.test_name
class ClassicTest(Test):
- diff_ignore_files = [
- # Stat files use a special stat differ, so don't include them
- # here.
+ # The diff ignore list contains all files that shouldn't be diffed
+ # using DiffOutFile. These files typically use special-purpose
+ # diff tools (e.g., DiffStatFile).
+ diff_ignore_files = (
+ # Stat files use a special stat differ
"stats.txt",
- ]
+ )
+
+ # These files should never be included in the list of
+ # reference files. This list should include temporary files
+ # and other files that we don't care about.
+ ref_ignore_files = (
+ )
def __init__(self, gem5, output_dir, config_tuple,
timeout=None,
@@ -251,7 +259,7 @@ class ClassicTest(Test):
for root, dirs, files in os.walk(ref_dir, topdown=False):
for f in files:
fpath = os.path.join(root[len(ref_dir) + 1:], f)
- if fpath not in ClassicTest.diff_ignore_files:
+ if fpath not in ClassicTest.ref_ignore_files:
yield fpath
def run_units(self):