adapt ZenDiscoveryUnitTests to removal of INGEST_ATTR, MASTER_ATTR and DATA_ATTR

This commit is contained in:
javanna 2016-03-25 10:47:02 +01:00 committed by Luca Cavanna
parent dd32bcea7a
commit 7bc4a35f9a
1 changed files with 2 additions and 3 deletions

View File

@ -105,9 +105,8 @@ public class ZenDiscoveryUnitTests extends ESTestCase {
ArrayList<DiscoveryNode> allNodes = new ArrayList<>();
for (int i = randomIntBetween(10, 20); i >= 0; i--) {
Map<String, String> attrs = new HashMap<>();
for (String attr : randomSubsetOf(
Arrays.asList(DiscoveryNode.INGEST_ATTR, DiscoveryNode.DATA_ATTR, DiscoveryNode.MASTER_ATTR))) {
attrs.put(attr, randomBoolean() + "");
for (DiscoveryNode.Role role : randomSubsetOf(Arrays.asList(DiscoveryNode.Role.values()))) {
attrs.put(role.getRoleName(), Boolean.toString(randomBoolean()));
}
DiscoveryNode node = new DiscoveryNode("node_" + i, "id_" + i, DummyTransportAddress.INSTANCE, attrs, Version.CURRENT);