use of com.axway.ats.log.autodb.DbAppenderConfiguration in project ats-framework by Axway.
the class Test_DbAppenderConfiguration method gettersAndSettersPositive.
@Test
public void gettersAndSettersPositive() {
DbAppenderConfiguration appenderConfig = new DbAppenderConfiguration();
appenderConfig.setHost("host1");
assertEquals("host1", appenderConfig.getHost());
appenderConfig.setDatabase("db1");
assertEquals("db1", appenderConfig.getDatabase());
appenderConfig.setUser("user1");
assertEquals("user1", appenderConfig.getUser());
appenderConfig.setPassword("pass1");
assertEquals("pass1", appenderConfig.getPassword());
appenderConfig.setEnableCheckpoints(true);
assertEquals(true, appenderConfig.getEnableCheckpoints());
}
use of com.axway.ats.log.autodb.DbAppenderConfiguration in project ats-framework by Axway.
the class Test_DbAppenderConfiguration method validatePositive.
@Test
public void validatePositive() throws InvalidAppenderConfigurationException {
DbAppenderConfiguration appenderConfig = new DbAppenderConfiguration();
appenderConfig.setHost("host1");
appenderConfig.setDatabase("db1");
appenderConfig.setUser("user1");
appenderConfig.setPassword("pass1");
appenderConfig.setEnableCheckpoints(true);
appenderConfig.validate();
}
use of com.axway.ats.log.autodb.DbAppenderConfiguration in project ats-framework by Axway.
the class Test_DbAppenderConfiguration method validateNegativeNoDatabase.
@Test(expected = InvalidAppenderConfigurationException.class)
public void validateNegativeNoDatabase() throws InvalidAppenderConfigurationException {
DbAppenderConfiguration appenderConfig = new DbAppenderConfiguration();
appenderConfig.setHost("host1");
appenderConfig.validate();
}
use of com.axway.ats.log.autodb.DbAppenderConfiguration in project ats-framework by Axway.
the class Test_DbAppenderConfiguration method validateNegativeNoUser.
@Test(expected = InvalidAppenderConfigurationException.class)
public void validateNegativeNoUser() throws InvalidAppenderConfigurationException {
DbAppenderConfiguration appenderConfig = new DbAppenderConfiguration();
appenderConfig.setHost("host1");
appenderConfig.setDatabase("db1");
appenderConfig.validate();
}
use of com.axway.ats.log.autodb.DbAppenderConfiguration in project ats-framework by Axway.
the class Test_DbAppenderConfiguration method validateNegativeNoPassword.
@Test(expected = InvalidAppenderConfigurationException.class)
public void validateNegativeNoPassword() throws InvalidAppenderConfigurationException {
DbAppenderConfiguration appenderConfig = new DbAppenderConfiguration();
appenderConfig.setHost("host1");
appenderConfig.setDatabase("db1");
appenderConfig.setUser("user1");
appenderConfig.validate();
}
Aggregations