Commit 8f4cd90e authored by machenbach's avatar machenbach Committed by Commit bot

[test] Clobber unclean test262-es6 checkouts.

Review URL: https://codereview.chromium.org/1173753004

Cr-Commit-Position: refs/heads/master@{#28894}
parent 37be1d5e
...@@ -131,6 +131,16 @@ class Test262TestSuite(testsuite.TestSuite): ...@@ -131,6 +131,16 @@ class Test262TestSuite(testsuite.TestSuite):
archive_name = os.path.join(self.root, "tc39-test262-%s.tar.gz" % revision) archive_name = os.path.join(self.root, "tc39-test262-%s.tar.gz" % revision)
directory_name = os.path.join(self.root, "data") directory_name = os.path.join(self.root, "data")
directory_old_name = os.path.join(self.root, "data.old") directory_old_name = os.path.join(self.root, "data.old")
# Clobber if the test is in an outdated state, i.e. if there are any other
# archive files present.
archive_files = [f for f in os.listdir(self.root)
if f.startswith("tc39-test262-")]
if len(archive_files) > 1 or archive_name not in archive_files:
print "Clobber outdated test archives ..."
for f in archive_files:
os.remove(os.path.join(self.root, f))
if not os.path.exists(archive_name): if not os.path.exists(archive_name):
print "Downloading test data from %s ..." % archive_url print "Downloading test data from %s ..." % archive_url
utils.URLRetrieve(archive_url, archive_name) utils.URLRetrieve(archive_url, archive_name)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment