1
1
mirror of https://github.com/henrydcase/pqc.git synced 2024-11-26 17:31:38 +00:00

Detect cron builds on Travis CI

This commit is contained in:
Thom Wiggers 2019-04-23 09:42:10 +02:00
parent 28358b579d
commit 029146566e
No known key found for this signature in database
GPG Key ID: 001BB0A7CE26E363

View File

@ -85,7 +85,8 @@ def skip_windows(message="This test is not supported on Windows"):
def slow_test(f):
@functools.wraps(f)
def wrapper(*args, **kwargs):
if 'CI' in os.environ and 'RUN_SLOW' not in os.environ:
if ('CI' in os.environ and 'RUN_SLOW' not in os.environ and
os.environ.get('TRAVIS_EVENT_TYPE') != 'cron'):
raise unittest.SkipTest("Slow test skipped on CI run")
return f(*args, **kwargs)
return wrapper