MCPcopy Create free account
hub / github.com/pytest-dev/pytest / rlf

Method rlf

testing/test_cacheprovider.py:509–517  ·  view source on GitHub ↗
(fail_import, fail_run)

Source from the content-addressed store, hash-verified

507 )
508
509 def rlf(fail_import, fail_run):
510 monkeypatch.setenv("FAILIMPORT", str(fail_import))
511 monkeypatch.setenv("FAILTEST", str(fail_run))
512
513 pytester.runpytest("-q")
514 config = pytester.parseconfigure()
515 assert config.cache is not None
516 lastfailed = config.cache.get("cache/lastfailed", -1)
517 return lastfailed
518
519 lastfailed = rlf(fail_import=0, fail_run=0)
520 assert lastfailed == -1

Callers

nothing calls this directly

Calls 4

setenvMethod · 0.80
runpytestMethod · 0.45
parseconfigureMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected