From bb24e7ab9ef4a1a97e00575f8c13497ec6a3e32d Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Fri, 25 Sep 2026 11:56:29 +0200 Subject: fix: bump dotless build number in download URLs Some upstreams name tarballs by a dotless build number while the SlackBuild VERSION is dotted (sublime_text: VERSION 4.2.00, URL build_4200), so the version swap missed the URL and the md5 was recomputed for the old tarball. Also swap the dotless form, only inside URLs and only as a whole number, leaving md5 hex alone. Co-Authored-By: Claude Opus 5.5 --- tests/mkhint_test.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'tests/mkhint_test.sh') diff --git a/tests/mkhint_test.sh b/tests/mkhint_test.sh index 2e885dd..36b0676 100755 --- a/tests/mkhint_test.sh +++ b/tests/mkhint_test.sh @@ -542,6 +542,22 @@ assert_contains "URL updated" "$MOCK_HINT/curl.hint" 'curl-8. assert_not_contains "MD5SUM updated" "$MOCK_HINT/curl.hint" 'abc123def456' assert_file_exists "backup created" "$MOCK_HINT/curl.hint.bak" +# ── T93: dotless build number in URL (sublime_text 4.2.00 ↔ build 4200) ─────── +echo "" +echo "T93: --hintfile -V 4.2.15 → URL build_4200 bumped to build_4215" +cat > "$MOCK_HINT/curl.hint" << 'EOF' +VERSION="4.2.00" +DOWNLOAD="UNSUPPORTED" +MD5SUM="" +DOWNLOAD_x86_64="https://download.example.org/app_build_4200_x64.tar.xz" +MD5SUM_x86_64="4200aaaabbbbccccddddeeeeffff0000" +EOF +run_mkhint -f curl -V 4.2.15 +assert_contains "VERSION updated" "$MOCK_HINT/curl.hint" 'VERSION="4.2.15"' +assert_contains "URL build bumped" "$MOCK_HINT/curl.hint" 'app_build_4215_x64' +assert_not_contains "old md5 gone" "$MOCK_HINT/curl.hint" '4200aaaa' +assert_not_contains "md5 not dotless-swapped" "$MOCK_HINT/curl.hint" '4215aaaa' + # ── T7: --hintfile -v -N → version + md5 updated + NODOWNLOAD ───────────────── echo "" echo "T7: --hintfile -v -N → version + md5 + NODOWNLOAD=yes" -- cgit v1.2.3