зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1190371 - [mozrunner] make mozcrash an optional dependency of mozrunner. r=ted
--HG-- extra : rebase_source : 0616b5742b2393a7cd2f139c369ead8d856df807
This commit is contained in:
Родитель
f2b18d2885
Коммит
e1322faaea
|
@ -10,7 +10,10 @@ import traceback
|
|||
|
||||
from mozlog import get_default_logger
|
||||
from mozprocess import ProcessHandler
|
||||
import mozcrash
|
||||
try:
|
||||
import mozcrash
|
||||
except ImportError:
|
||||
mozcrash = None
|
||||
|
||||
from ..application import DefaultContext
|
||||
from ..errors import RunnerNotStartedError
|
||||
|
@ -192,21 +195,27 @@ class BaseRunner(object):
|
|||
if logger is not None:
|
||||
if test_name is None:
|
||||
test_name = "runner.py"
|
||||
self.crashed += mozcrash.log_crashes(
|
||||
logger,
|
||||
dump_directory,
|
||||
self.symbols_path,
|
||||
dump_save_path=dump_save_path,
|
||||
test=test_name)
|
||||
if mozcrash:
|
||||
self.crashed += mozcrash.log_crashes(
|
||||
logger,
|
||||
dump_directory,
|
||||
self.symbols_path,
|
||||
dump_save_path=dump_save_path,
|
||||
test=test_name)
|
||||
else:
|
||||
logger.warning("Can not log crashes without mozcrash")
|
||||
else:
|
||||
crashed = mozcrash.check_for_crashes(
|
||||
dump_directory,
|
||||
self.symbols_path,
|
||||
dump_save_path=dump_save_path,
|
||||
test_name=test_name,
|
||||
quiet=quiet)
|
||||
if crashed:
|
||||
self.crashed += 1
|
||||
if mozcrash:
|
||||
crashed = mozcrash.check_for_crashes(
|
||||
dump_directory,
|
||||
self.symbols_path,
|
||||
dump_save_path=dump_save_path,
|
||||
test_name=test_name,
|
||||
quiet=quiet)
|
||||
if crashed:
|
||||
self.crashed += 1
|
||||
else:
|
||||
logger.warning("Can not log crashes without mozcrash")
|
||||
except:
|
||||
traceback.print_exc()
|
||||
|
||||
|
|
|
@ -10,8 +10,7 @@ PACKAGE_VERSION = '6.10'
|
|||
|
||||
desc = """Reliable start/stop/configuration of Mozilla Applications (Firefox, Thunderbird, etc.)"""
|
||||
|
||||
deps = ['mozcrash >= 0.14',
|
||||
'mozdevice >= 0.37',
|
||||
deps = ['mozdevice >= 0.37',
|
||||
'mozfile >= 1.0',
|
||||
'mozinfo >= 0.7',
|
||||
'mozlog >= 3.0',
|
||||
|
@ -19,6 +18,8 @@ deps = ['mozcrash >= 0.14',
|
|||
'mozprofile >= 0.18',
|
||||
]
|
||||
|
||||
EXTRAS_REQUIRE = {'crash': ['mozcrash >= 0.14']}
|
||||
|
||||
# we only support python 2 right now
|
||||
assert sys.version_info[0] == 2
|
||||
|
||||
|
@ -44,7 +45,8 @@ setup(name=PACKAGE_NAME,
|
|||
'resources/metrotestharness.exe'
|
||||
]},
|
||||
zip_safe=False,
|
||||
install_requires = deps,
|
||||
install_requires=deps,
|
||||
extras_require=EXTRAS_REQUIRE,
|
||||
entry_points="""
|
||||
# -*- Entry points: -*-
|
||||
[console_scripts]
|
||||
|
|
Загрузка…
Ссылка в новой задаче