summaryrefslogtreecommitdiff
path: root/scripts/tests.py
AgeCommit message (Collapse)Author
2026-06-24Avoided breaking sha1sum verification in the generated checksum.txt file.Natalia
When doing releases, the `do_django_release.py` script included, in the generated checksum.txt file, a "<commit hash> <version>" section for the git tag for the release. This line was byte-for-byte a GNU coreutils checksum line, since the commit hash is 40 hex characters, therefore "sha1sum --check" parsed it as an entry for a file named after the version (e.g. "6.1b1"), failed to open that file, and aborted the `verify_release.sh` script. Reworded the line as prose so it is no longer mistaken for a checksum entry.
2026-05-27Refactored release script to support testing in isolation.Natalia
Extracted helpers (get_commit_hash, parse_major_version, find_release_artifacts, create_checksum_file) and isolated all code with side-effects in main() guarded by __name__ == "__main__", allowing the module to be imported without starting the release process. Added tests for the new helpers in scripts/tests.py. Thanks Jacob Walls for the review and IRL test.
2026-03-06Added python script suitable for using as prepare-commit-msg git hook.Natalia