test(relinker): update runtime layout expectations for tree output

This commit is contained in:
boykopovar 2026-10-13 11:14:02 +03:00
parent 56c2a53188
commit 6f2e4b6902
2 changed files with 2 additions and 2 deletions

View File

@ -114,7 +114,7 @@ def main():
artifact = case / "app0" / "sce_module" / "needed.prx.guest.prx"
assert artifact.read_bytes().startswith(b"MZ" if windows else b"\x7fELF"), artifact
assert list((case / "app0").rglob("*.guest.prx")) == [artifact]
assert " sce_module/needed.prx.guest.prx\n" in result.stdout, result.stdout
assert " `-- sce_module/\n `-- needed.prx.guest.prx\n" in result.stdout, result.stdout
if windows and os.name == "nt":
run = subprocess.run([str(output)], capture_output=True, text=True, timeout=30)
assert run.returncode == 42, (run.returncode, run.stdout, run.stderr)

View File

@ -53,7 +53,7 @@ def main():
alignment = max(segment[7] for segment in segments)
if alignment != 0x4000 or first[3] % alignment != 0 or first[7] != alignment:
raise AssertionError(("first PT_LOAD is not aligned to the largest segment alignment", segments))
assert "output.elf\nlibs/\n *.prx\napp0/" in result.stdout, result.stdout
assert " |-- output.elf\n |-- libs/\n | `-- *.prx (system libraries)\n `-- app0/" in result.stdout, result.stdout
named_exe = Path(directory) / "linux.EXE"
warning = subprocess.run([str(relinker), "--skip-sce-module", str(source), str(named_exe)], capture_output=True, text=True, timeout=20)
assert warning.returncode == 0, (warning.stdout, warning.stderr)