Fix compilation due to upstream change

Original commit: elastic/x-pack-elasticsearch@57d834841d
This commit is contained in:
Dimitrios Athanasiou 2017-09-26 12:08:15 +01:00
parent c46e09902d
commit 5ad170a7ed
3 changed files with 12 additions and 4 deletions

View File

@ -46,7 +46,9 @@ public class ESNativeRealmMigrateToolTests extends CommandTestCase {
@Override
protected Environment createEnv(Terminal terminal, Map<String, String> settings) throws UserException {
return new Environment(Settings.builder().put(settings).build());
Settings.Builder builder = Settings.builder();
settings.forEach((k,v) -> builder.put(k, v));
return new Environment(builder.build());
}
};

View File

@ -100,7 +100,9 @@ public class SetupPasswordToolTests extends CommandTestCase {
return new AutoSetup() {
@Override
protected Environment createEnv(Terminal terminal, Map<String, String> settings) throws UserException {
return new Environment(Settings.builder().put(settings).build());
Settings.Builder builder = Settings.builder();
settings.forEach((k,v) -> builder.put(k, v));
return new Environment(builder.build());
}
};
}
@ -110,7 +112,9 @@ public class SetupPasswordToolTests extends CommandTestCase {
return new InteractiveSetup() {
@Override
protected Environment createEnv(Terminal terminal, Map<String, String> settings) throws UserException {
return new Environment(Settings.builder().put(settings).build());
Settings.Builder builder = Settings.builder();
settings.forEach((k,v) -> builder.put(k, v));
return new Environment(builder.build());
}
};
}

View File

@ -50,7 +50,9 @@ public class SystemKeyToolTests extends CommandTestCase {
@Override
protected Environment createEnv(Terminal terminal, Map<String, String> settings) throws UserException {
return new Environment(Settings.builder().put(settings).build());
Settings.Builder builder = Settings.builder();
settings.forEach((k,v) -> builder.put(k, v));
return new Environment(builder.build());
}
};