Make some assumptions on 'check' unit tests after talking with jimi-c.

Unit tests will now only all pass on ansible 1.8+.  We'll probably need
to revisit this, definitely for v2 if for no other reason
This commit is contained in:
Matthew Jones 2015-01-22 11:15:16 -05:00
parent 7e822c34d5
commit 12855e6c44

View File

@ -602,6 +602,12 @@ class RunJobTest(BaseCeleryTest):
qs = qs.exclude(event='runner_on_failed')
else:
qs = qs.exclude(event=('runner_on_%s' % runner_status))
if runner_status == 'skipped':
# NOTE: Ansible >= 1.8.2 emits a runner_on_ok event in some cases
# of runner_on_skipped. We may need to revisit this if this assumption
# is not universal
qs = qs.exclude(event='runner_on_ok')
if async:
if runner_status == 'failed':
qs = qs.exclude(event='runner_on_ok')