tests.test_verify module¶
Tests for repomatic.release.verify: native header verification.
- tests.test_verify.test_matching_arch(tmp_path, target, payload)[source]¶
Binary with matching architecture passes verification.
- tests.test_verify.test_mismatched_arch(tmp_path, target, payload)[source]¶
Binary with mismatched architecture or format raises ValueError.
- tests.test_verify.test_verify_binary_rejects_an_unknown_target(tmp_path)[source]¶
The command refuses a target outside the build roster, before any read.
- tests.test_verify.test_elf_info_without_verneed(tmp_path)[source]¶
A sectionless ELF reports its machine and no glibc requirement.
- tests.test_verify.test_elf_info_skips_glibc_feature_versions(tmp_path)[source]¶
A feature entry like
GLIBC_ABI_DT_RELRsets no glibc floor.Files linked with packed relocations require it, like the Python interpreter Arch Linux ships.
- tests.test_verify.test_elf_info_orders_glibc_versions_numerically(tmp_path)[source]¶
2.4is older than2.38, which a comparison of strings gets wrong.
- tests.test_verify.test_elf_info_reads_both_classes_and_byte_orders(tmp_path, wide, big_endian)[source]¶
The parser follows the class and byte order the identification declares.
- tests.test_verify.test_elf_info_rejects_a_truncated_header(tmp_path)[source]¶
A file cut inside its ELF header is reported, not read as sectionless.
- tests.test_verify.test_macho_info_fat_slices(tmp_path)[source]¶
CPU types accumulate and the floor maxes across fat slices.
- tests.test_verify.test_pe_machine_parsing(tmp_path)[source]¶
The COFF machine field is read from PE headers, None elsewhere.
- tests.test_verify.test_running_interpreter_parses()[source]¶
The parsers agree with the running interpreter’s own executable.
- tests.test_verify.test_floor_within_bounds_macos(tmp_path)[source]¶
Files at or below the declared macOS floor pass verification.
- tests.test_verify.test_floor_exceeded_macos(tmp_path)[source]¶
A dist file above the declared macOS floor fails verification.