]> git.ipfire.org Git - thirdparty/git.git/commit
t1006: update 'run_tests' to test generic object specifiers
authorVictoria Dye <vdye@github.com>
Mon, 2 Jun 2025 18:55:53 +0000 (18:55 +0000)
committerJunio C Hamano <gitster@pobox.com>
Tue, 3 Jun 2025 19:08:58 +0000 (12:08 -0700)
commit9fd38038b9cf7d221bfa2d2ee95c8fad6d8b3d64
tree2099362b8ca48ebca0e7d3a1c1de4b63db7f0a76
parent0bd2d791cc9f745ebaedafc0e1cbebdebe41343e
t1006: update 'run_tests' to test generic object specifiers

Update the 'run_tests' test wrapper so that the first argument may refer to
any specifier that uniquely identifies an object (e.g. a ref name,
'<OID>:<path>', '<OID>^{<type>}', etc.), rather than only a full object ID.

Also add tests that use non-OID identifiers, ensuring appropriate parsing in
'cat-file'. The identifiers used in some of the added tests include a space,
which is incompatible with the '%(rest)' atom. To accommodate that without
removing the test case, use 'test_expect_failure' when 'object_name'
includes a space.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Victoria Dye <vdye@github.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t1006-cat-file.sh