]> git.ipfire.org Git - thirdparty/git.git/commit
t98xx: fix Perforce tests with p4d r23 and newer
authorPatrick Steinhardt <ps@pks.im>
Wed, 31 Jul 2024 10:37:40 +0000 (12:37 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 31 Jul 2024 17:05:18 +0000 (10:05 -0700)
commit49f4fd901a97863c6458acaa0904b940dc827c40
tree240b8705bf7f2df2299bea7a3d718ca7cdf35568
parentd19b6cd2dd72dc811f19df4b32c7ed223256c3ee
t98xx: fix Perforce tests with p4d r23 and newer

Some of the tests in t98xx modify the Perforce depot in ways that the
tool wouldn't normally allow. This is done to test behaviour of git-p4
in certain edge cases that we have observed in the wild, but which
should in theory not be possible.

Naturally, modifying the depot on disk directly is quite intimate with
the tool and thus prone to breakage when Perforce updates the way that
data is stored. And indeed, those tests are broken nowadays with r23 of
Perforce. While a file revision was previously stored as a plain file
"depot/file,v", it is now stored in a directory "depot/file,d" with
compression.

Adapt those tests to handle both old- and new-style depot layouts.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t9800-git-p4-basic.sh
t/t9802-git-p4-filetype.sh
t/t9825-git-p4-handle-utf16-without-bom.sh