mirror of
https://github.com/RsyncProject/rsync.git
synced 2026-06-08 14:15:46 -04:00
The regression tests use test_xfail() (exit 78) to assert a known, documented
residual on platforms where the fix can't apply -- e.g. link-dest-relative-basis
XFAILs where the receiver has no openat2/O_RESOLVE_BENEATH and the portable
resolver rejects the '..' for safety. runtests.py counted exit 78 in the
generic else->failed branch, so a bare XFAIL failed the whole suite; tally it
separately ('N xfailed (expected)') and exclude it from the failure exit code.
Also add --race-timeout plumbing (race_timeout env) for race tests.
18 lines
601 B
Python
18 lines
601 B
Python
"""Exit codes a test reports to runtests.py (autotools test convention).
|
|
|
|
Shared by runtests.py (the harness, which reads these from each test) and
|
|
rsyncfns.py (the helpers, which exit with them) so the 0/1/2/77/78 values are
|
|
named in exactly one place. This module has no import-time side effects, so
|
|
runtests.py can import it without pulling in rsyncfns's environment checks.
|
|
"""
|
|
|
|
import enum
|
|
|
|
|
|
class Exit(enum.IntEnum):
|
|
PASS = 0
|
|
FAIL = 1
|
|
ERROR = 2 # the test could not run (e.g. missing environment)
|
|
SKIP = 77
|
|
XFAIL = 78 # expected failure: a known, documented residual
|