mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
Add the list of expected skips for Linux 2.x. Restructured the code a
little bit using a dictionary to avoid more code duplication as more platforms are supported.
This commit is contained in:
parent
a2be2d624a
commit
f73e30c3e3
1 changed files with 51 additions and 28 deletions
|
@ -399,13 +399,10 @@ class _Set:
|
||||||
data.sort()
|
data.sort()
|
||||||
return data
|
return data
|
||||||
|
|
||||||
class _ExpectedSkips:
|
_expectations = {
|
||||||
def __init__(self):
|
'win32':
|
||||||
self.valid = 0
|
"""
|
||||||
|
test_al
|
||||||
if sys.platform == "win32":
|
|
||||||
self.valid = 1
|
|
||||||
s = """test_al
|
|
||||||
test_cd
|
test_cd
|
||||||
test_cl
|
test_cl
|
||||||
test_commands
|
test_commands
|
||||||
|
@ -429,8 +426,34 @@ class _ExpectedSkips:
|
||||||
test_signal
|
test_signal
|
||||||
test_socketserver
|
test_socketserver
|
||||||
test_sunaudiodev
|
test_sunaudiodev
|
||||||
test_timing"""
|
test_timing
|
||||||
|
""",
|
||||||
|
'linux2':
|
||||||
|
"""
|
||||||
|
test_al
|
||||||
|
test_cd
|
||||||
|
test_cl
|
||||||
|
test_dl
|
||||||
|
test_gl
|
||||||
|
test_imgfile
|
||||||
|
test_largefile
|
||||||
|
test_nis
|
||||||
|
test_ntpath
|
||||||
|
test_socketserver
|
||||||
|
test_sunaudiodev
|
||||||
|
test_unicode_file
|
||||||
|
test_winreg
|
||||||
|
test_winsound
|
||||||
|
""",
|
||||||
|
}
|
||||||
|
|
||||||
|
class _ExpectedSkips:
|
||||||
|
def __init__(self):
|
||||||
|
self.valid = 0
|
||||||
|
if _expectations.has_key(sys.platform):
|
||||||
|
s = _expectations[sys.platform]
|
||||||
self.expected = _Set(s.split())
|
self.expected = _Set(s.split())
|
||||||
|
self.valid = 1
|
||||||
|
|
||||||
def isvalid(self):
|
def isvalid(self):
|
||||||
"Return true iff _ExpectedSkips knows about the current platform."
|
"Return true iff _ExpectedSkips knows about the current platform."
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue