def access_self(): assert get_current_job() is not None
def test_job_access_outside_job_fails(): """The current job is accessible only within a job context.""" assert not (yield from get_current_job())