mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
bug 1049202 - remove automationutils mozinfo workaround for non-mozharness Android tests. r=jmaher
This commit is contained in:
parent
13dcd9eb3e
commit
96a23f8aff
@ -15,28 +15,7 @@ import sys
|
||||
import tempfile
|
||||
from urlparse import urlparse
|
||||
import zipfile
|
||||
|
||||
try:
|
||||
import mozinfo
|
||||
except ImportError:
|
||||
# Stub out fake mozinfo since this is not importable on Android 4.0 Opt.
|
||||
# This should be fixed; see
|
||||
# https://bugzilla.mozilla.org/show_bug.cgi?id=650881
|
||||
mozinfo = type('mozinfo', (), dict(info={}))()
|
||||
mozinfo.isWin = mozinfo.isLinux = mozinfo.isUnix = mozinfo.isMac = False
|
||||
|
||||
# TODO! FILE: localautomation :/
|
||||
# mapping from would-be mozinfo attr <-> sys.platform
|
||||
mapping = {'isMac': ['mac', 'darwin'],
|
||||
'isLinux': ['linux', 'linux2'],
|
||||
'isWin': ['win32', 'win64'],
|
||||
}
|
||||
mapping = dict(sum([[(value, key) for value in values] for key, values in mapping.items()], []))
|
||||
attr = mapping.get(sys.platform)
|
||||
if attr:
|
||||
setattr(mozinfo, attr, True)
|
||||
if mozinfo.isLinux:
|
||||
mozinfo.isUnix = True
|
||||
import mozinfo
|
||||
|
||||
__all__ = [
|
||||
"ZipFileReader",
|
||||
|
Loading…
Reference in New Issue
Block a user