Skip to content

Commit

Permalink
testShrinkAfterUpgrade should only set mapping.single_type if bwc ver…
Browse files Browse the repository at this point in the history
…sion > 5.5.0

It was only added in #24317
  • Loading branch information
bleskes committed Mar 22, 2018
1 parent 892b7d5 commit a3e2d2a
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,10 @@ public void testShrinkAfterUpgrade() throws IOException {
if (runningAgainstOldCluster) {
XContentBuilder mappingsAndSettings = jsonBuilder();
mappingsAndSettings.startObject();
if (oldClusterVersion.major == 5 && randomBoolean()) {
// single type was added in 5.5.0 (see #24317)
if (oldClusterVersion.onOrAfter(Version.V_5_5_0) &&
oldClusterVersion.before(Version.V_6_0_0_beta1) &&
randomBoolean()) {
{
// test that mapping.single_type is correctly propagated on the shrinked index,
// if not, search will fail.
Expand Down

0 comments on commit a3e2d2a

Please sign in to comment.