diff --git a/x-pack/plugin/snapshot-repo-test-kit/src/internalClusterTest/java/org/elasticsearch/repositories/blobstore/testkit/RepositoryAnalysisFailureIT.java b/x-pack/plugin/snapshot-repo-test-kit/src/internalClusterTest/java/org/elasticsearch/repositories/blobstore/testkit/RepositoryAnalysisFailureIT.java index ba132938b238e..251d20dbc4c4f 100644 --- a/x-pack/plugin/snapshot-repo-test-kit/src/internalClusterTest/java/org/elasticsearch/repositories/blobstore/testkit/RepositoryAnalysisFailureIT.java +++ b/x-pack/plugin/snapshot-repo-test-kit/src/internalClusterTest/java/org/elasticsearch/repositories/blobstore/testkit/RepositoryAnalysisFailureIT.java @@ -341,7 +341,9 @@ public BytesReference onCompareAndExchange(BytesRegister register, BytesReferenc analyseRepository(request); assertFalse(sawSpuriousValue.get()); } catch (RepositoryVerificationException e) { - assertTrue(sawSpuriousValue.get()); + if (sawSpuriousValue.get() == false) { + fail(e, "did not see spurious value, so why did the verification fail?"); + } } }