Skip to content

Commit

Permalink
Clean up IndexShardTests.testCheckpointReffreshListenerWithNull
Browse files Browse the repository at this point in the history
Signed-off-by: Marc Handalian <[email protected]>
  • Loading branch information
mch2 committed Aug 1, 2023
1 parent 703785e commit 15b28eb
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -3762,7 +3762,8 @@ public void testCheckpointRefreshListener() throws IOException {
* here we are passing null in place of SegmentReplicationCheckpointPublisher and testing on index shard if CheckpointRefreshListener is not added to the InternalrefreshListerners List
*/
public void testCheckpointRefreshListenerWithNull() throws IOException {
IndexShard shard = newStartedShard(p -> newShard(null), true);
final SegmentReplicationCheckpointPublisher publisher = null;
IndexShard shard = newStartedShard(p -> newShard(true, publisher), true);
List<ReferenceManager.RefreshListener> refreshListeners = shard.getEngine().config().getInternalRefreshListener();
assertFalse(refreshListeners.stream().anyMatch(e -> e instanceof CheckpointRefreshListener));
closeShards(shard);
Expand Down

0 comments on commit 15b28eb

Please sign in to comment.