use of org.neo4j.kernel.configuration.ConfigurationValidator in project neo4j by neo4j.
the class ServerBootstrapperTest method shouldNotThrowNullPointerExceptionIfConfigurationValidationFails.
@Test
public void shouldNotThrowNullPointerExceptionIfConfigurationValidationFails() throws Exception {
// given
ServerBootstrapper serverBootstrapper = new ServerBootstrapper() {
@Override
protected NeoServer createNeoServer(Config config, GraphDatabaseDependencies dependencies, LogProvider userLogProvider) {
return mock(NeoServer.class);
}
@Nonnull
@Override
protected Collection<ConfigurationValidator> configurationValidators() {
return Collections.emptyList();
}
};
File dir = Files.createTempDirectory("test-server-bootstrapper").toFile();
dir.deleteOnExit();
// when
serverBootstrapper.start(dir, Optional.empty());
// then no exceptions are thrown and
assertThat(suppress.getOutputVoice().lines(), not(empty()));
}
use of org.neo4j.kernel.configuration.ConfigurationValidator in project neo4j by neo4j.
the class EnterpriseBootstrapper method configurationValidators.
@Override
@Nonnull
protected Collection<ConfigurationValidator> configurationValidators() {
ArrayList<ConfigurationValidator> validators = new ArrayList<>();
validators.addAll(super.configurationValidators());
validators.add(new HaConfigurationValidator());
validators.add(new CausalClusterConfigurationValidator());
return validators;
}
Aggregations