use of fish.payara.nucleus.notification.log.LogNotifierConfigurationExecutionOptions in project Payara by payara.
the class NotificationExecutionOptionsTest method logNotifierConfigurationExecutionOptionRemovedSuccessfully.
@Test
public void logNotifierConfigurationExecutionOptionRemovedSuccessfully() {
LogNotifierConfigurationExecutionOptions logExecOptions = new LogNotifierConfigurationExecutionOptions();
executionOptions.addNotifierConfigurationExecutionOption(logExecOptions);
executionOptions.removeNotifierConfigurationExecutionOption(logExecOptions);
assertNotNull(executionOptions.getNotifierConfigurationExecutionOptionsList());
assertThat(executionOptions.getNotifierConfigurationExecutionOptionsList().size(), is(0));
}
use of fish.payara.nucleus.notification.log.LogNotifierConfigurationExecutionOptions in project Payara by payara.
the class LogNotifierConfigurationExecutionOptionsFactoryMock method notifierConfigurationExecutionOptionBuildsSuccessfullyForLog.
@Test
public void notifierConfigurationExecutionOptionBuildsSuccessfullyForLog() {
LogNotifierConfiguration logNotifierConfiguration = mock(LogNotifierConfiguration.class);
when(logNotifierConfiguration.getEnabled()).thenReturn("true");
LogNotifierConfigurationExecutionOptions executionOptions = factory.build(logNotifierConfiguration);
assertThat(executionOptions.getNotifierType(), is(NotifierType.LOG));
assertThat(executionOptions.isEnabled(), is(true));
}
use of fish.payara.nucleus.notification.log.LogNotifierConfigurationExecutionOptions in project Payara by payara.
the class NotificationExecutionOptionsTest method logNotifierConfigurationExecutionOptionEnabledSuccessfully.
@Test
public void logNotifierConfigurationExecutionOptionEnabledSuccessfully() {
NotificationExecutionOptions executionOptions = new NotificationExecutionOptions();
LogNotifierConfigurationExecutionOptions logExecOptions = new LogNotifierConfigurationExecutionOptions();
logExecOptions.setEnabled(true);
executionOptions.addNotifierConfigurationExecutionOption(logExecOptions);
assertNotNull(executionOptions.getNotifierConfigurationExecutionOptionsList());
assertThat(executionOptions.isNotifierServiceEnabled(LOG), is(true));
}
use of fish.payara.nucleus.notification.log.LogNotifierConfigurationExecutionOptions in project Payara by payara.
the class NotificationExecutionOptionsTest method logNotifierConfigurationExecutionOptionAddedSuccessfully.
@Test
public void logNotifierConfigurationExecutionOptionAddedSuccessfully() {
executionOptions.addNotifierConfigurationExecutionOption(new LogNotifierConfigurationExecutionOptions());
assertNotNull(executionOptions.getNotifierConfigurationExecutionOptionsList());
assertThat(executionOptions.getNotifierConfigurationExecutionOptionsList().size(), is(1));
assertThat(executionOptions.getNotifierConfigurationExecutionOptionsList().get(LOG), is(instanceOf(LogNotifierConfigurationExecutionOptions.class)));
}
Aggregations