t5310-pack-bitmaps: make JGit tests work with GIT_TEST_SPLIT_INDEX
commit87a6bb701a04d4543314f6f7172f2f95fa298d29
authorSZEDER Gábor <szeder.dev@gmail.com>
Thu, 10 May 2018 13:58:52 +0000 (10 15:58 +0200)
committerJunio C Hamano <gitster@pobox.com>
Fri, 11 May 2018 03:14:34 +0000 (11 12:14 +0900)
tree4740e227d1c72bec2919e40ba84c0371e41ea33f
parent468165c1d8a442994a825f3684528361727cd8c0
t5310-pack-bitmaps: make JGit tests work with GIT_TEST_SPLIT_INDEX

The two JGit tests 'we can read jgit bitmaps' and 'jgit can read our
bitmaps' in 't5310-pack-bitmaps.sh' fail when run with
GIT_TEST_SPLIT_INDEX=YesPlease.  Both tests create a clone of the test
repository to check bitmap interoperability with JGit.  With split
indexes enabled the index in the clone repositories contains the
'link' extension, which JGit doesn't support and, consequently, an
exception aborts it:

  <...>
  org.eclipse.jgit.api.errors.JGitInternalException: DIRC extension 'link' not supported by this version.
          at org.eclipse.jgit.dircache.DirCache.readFrom(DirCache.java:562)
  <...>

Since testing bitmaps doesn't need a worktree in the first place,
let's just create bare clones for the two JGit tests, so the cloned
won't have an index, and these two tests can be executed even with
split index enabled.

Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
Reviewed-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t5310-pack-bitmaps.sh