]> git.ipfire.org Git - thirdparty/git.git/commit
t9700: make hash size independent
authorbrian m. carlson <sandals@crustytoothpaste.net>
Wed, 29 Jul 2020 23:14:15 +0000 (23:14 +0000)
committerJunio C Hamano <gitster@pobox.com>
Thu, 30 Jul 2020 16:16:48 +0000 (09:16 -0700)
commite0a646ed4fd7ae0c3320f7fa56d6a7d6bbaa8142
tree7cea5f3929db010f9a7f5f8ad79c2dc34fc56e0e
parent6ff6a6759de3b85b591f334e13b63456804be328
t9700: make hash size independent

The Perl test script for t9700 was matching on exactly 40 hex
characters.  With SHA-256, we'll have 64 hex-character object IDs.
Create a variable with a regex which matches exactly 40 or 64 hex
characters and use that to match the output.  Note that both of the uses
of this can be anchored, which makes the code simpler, so do that as
well.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Reviewed-by: Eric Sunshine <sunshine@sunshineco.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t9700/test.pl