Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(50)

Side by Side Diff: test/test262/testcfg.py

Issue 11308033: Update Test262 harness to recent version. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « test/test262/test262.status ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2012 the V8 project authors. All rights reserved. 1 # Copyright 2012 the V8 project authors. All rights reserved.
2 # Redistribution and use in source and binary forms, with or without 2 # Redistribution and use in source and binary forms, with or without
3 # modification, are permitted provided that the following conditions are 3 # modification, are permitted provided that the following conditions are
4 # met: 4 # met:
5 # 5 #
6 # * Redistributions of source code must retain the above copyright 6 # * Redistributions of source code must retain the above copyright
7 # notice, this list of conditions and the following disclaimer. 7 # notice, this list of conditions and the following disclaimer.
8 # * Redistributions in binary form must reproduce the above 8 # * Redistributions in binary form must reproduce the above
9 # copyright notice, this list of conditions and the following 9 # copyright notice, this list of conditions and the following
10 # disclaimer in the documentation and/or other materials provided 10 # disclaimer in the documentation and/or other materials provided
(...skipping 18 matching lines...) Expand all
29 import hashlib 29 import hashlib
30 import os 30 import os
31 import sys 31 import sys
32 import tarfile 32 import tarfile
33 import urllib 33 import urllib
34 34
35 from testrunner.local import testsuite 35 from testrunner.local import testsuite
36 from testrunner.objects import testcase 36 from testrunner.objects import testcase
37 37
38 38
39 TEST_262_ARCHIVE_REVISION = "fb327c439e20" # This is the r334 revision. 39 TEST_262_ARCHIVE_REVISION = "53c4ade82d14" # This is the r360 revision.
40 TEST_262_ARCHIVE_MD5 = "307acd166ec34629592f240dc12d57ed" 40 TEST_262_ARCHIVE_MD5 = "5fa4918b00e5d60e57bdd3c05deaeb0c"
41 TEST_262_URL = "http://hg.ecmascript.org/tests/test262/archive/%s.tar.bz2" 41 TEST_262_URL = "http://hg.ecmascript.org/tests/test262/archive/%s.tar.bz2"
42 TEST_262_HARNESS = ["sta.js"] 42 TEST_262_HARNESS = ["sta.js", "testBuiltInObject.js"]
43 TEST_262_SKIP = ["intl402"]
43 44
44 45
45 class Test262TestSuite(testsuite.TestSuite): 46 class Test262TestSuite(testsuite.TestSuite):
46 47
47 def __init__(self, name, root): 48 def __init__(self, name, root):
48 super(Test262TestSuite, self).__init__(name, root) 49 super(Test262TestSuite, self).__init__(name, root)
49 self.testroot = os.path.join(root, "data", "test", "suite") 50 self.testroot = os.path.join(root, "data", "test", "suite")
50 self.harness = [os.path.join(self.root, "data", "test", "harness", f) 51 self.harness = [os.path.join(self.root, "data", "test", "harness", f)
51 for f in TEST_262_HARNESS] 52 for f in TEST_262_HARNESS]
52 self.harness += [os.path.join(self.root, "harness-adapt.js")] 53 self.harness += [os.path.join(self.root, "harness-adapt.js")]
53 54
54 def CommonTestName(self, testcase): 55 def CommonTestName(self, testcase):
55 return testcase.path.split(os.path.sep)[-1] 56 return testcase.path.split(os.path.sep)[-1]
56 57
57 def ListTests(self, context): 58 def ListTests(self, context):
58 tests = [] 59 tests = []
59 for dirname, dirs, files in os.walk(self.testroot): 60 for dirname, dirs, files in os.walk(self.testroot):
60 for dotted in [x for x in dirs if x.startswith(".")]: 61 for dotted in [x for x in dirs if x.startswith(".")]:
61 dirs.remove(dotted) 62 dirs.remove(dotted)
63 for skipped in [x for x in dirs if x in TEST_262_SKIP]:
64 dirs.remove(skipped)
62 dirs.sort() 65 dirs.sort()
63 files.sort() 66 files.sort()
64 for filename in files: 67 for filename in files:
65 if filename.endswith(".js"): 68 if filename.endswith(".js"):
66 testname = os.path.join(dirname[len(self.testroot) + 1:], 69 testname = os.path.join(dirname[len(self.testroot) + 1:],
67 filename[:-3]) 70 filename[:-3])
68 case = testcase.TestCase(self, testname) 71 case = testcase.TestCase(self, testname)
69 tests.append(case) 72 tests.append(case)
70 return tests 73 return tests
71 74
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 return ['d8'] 224 return ['d8']
222 225
223 def GetTestStatus(self, sections, defs): 226 def GetTestStatus(self, sections, defs):
224 status_file = join(self.root, 'test262.status') 227 status_file = join(self.root, 'test262.status')
225 if exists(status_file): 228 if exists(status_file):
226 test.ReadConfigurationInto(status_file, sections, defs) 229 test.ReadConfigurationInto(status_file, sections, defs)
227 230
228 231
229 def GetConfiguration(context, root): 232 def GetConfiguration(context, root):
230 return Test262TestConfiguration(context, root) 233 return Test262TestConfiguration(context, root)
OLDNEW
« no previous file with comments | « test/test262/test262.status ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698