浏览代码

TEST: use new nodes assumption in testUpdateSnapshotStatus

Using an assertion is not correct here as the list of new nodes can be
empty.
Nhat Nguyen 7 年之前
父节点
当前提交
0edde25f09
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      qa/mixed-cluster/src/test/java/org/elasticsearch/backwards/IndexingIT.java

+ 1 - 1
qa/mixed-cluster/src/test/java/org/elasticsearch/backwards/IndexingIT.java

@@ -233,7 +233,7 @@ public class IndexingIT extends ESRestTestCase {
 
 
     public void testUpdateSnapshotStatus() throws Exception {
     public void testUpdateSnapshotStatus() throws Exception {
         Nodes nodes = buildNodeAndVersions();
         Nodes nodes = buildNodeAndVersions();
-        assertThat(nodes.getNewNodes(), not(empty()));
+        assumeFalse("new nodes is empty", nodes.getNewNodes().isEmpty());
         logger.info("cluster discovered: {}", nodes.toString());
         logger.info("cluster discovered: {}", nodes.toString());
 
 
         // Create the repository before taking the snapshot.
         // Create the repository before taking the snapshot.