use of org.apache.derbyTesting.junit.CleanDatabaseTestSetup in project derby by apache.
the class I18NImportExport method suite.
public static Test suite() {
BaseTestSuite suite = new BaseTestSuite("I18NImportExport");
suite.addTest(new CleanDatabaseTestSetup(new I18NImportExport("I18NImportExport")));
return getIJConfig(new SupportFilesSetup(suite, new String[] { "functionTests/tests/i18n/data/Tab1_fr.ctrl", "functionTests/tests/i18n/data/Tab1_il.ctrl", "functionTests/tests/i18n/data/Tab1_jp.ctrl" }));
}
use of org.apache.derbyTesting.junit.CleanDatabaseTestSetup in project derby by apache.
the class ConnectTest method suite.
public static Test suite() {
if (JDBC.vmSupportsJSR169())
// is not supported with JSR169
return new BaseTestSuite("empty ConnectTest:DriverManager not supported");
else {
BaseTestSuite suite = new BaseTestSuite("ConnectTest suite");
suite.addTest(TestConfiguration.defaultSuite(ConnectTest.class));
// Derby2026 test uses explicit client connection so not relevant to embedded
suite.addTest(TestConfiguration.clientServerDecorator(new ConnectTest("clientTestDerby2026LoginTimeout")));
return new CleanDatabaseTestSetup(suite);
}
}
use of org.apache.derbyTesting.junit.CleanDatabaseTestSetup in project derby by apache.
the class Bug5054Test method suite.
/**
* Returns the implemented tests.
*
* @return An instance of <code>Test</code> with the implemented tests to
* run.
*/
public static Test suite() {
BaseTestSuite suite = new BaseTestSuite("Bug5054Test");
Test test = new CleanDatabaseTestSetup(TestConfiguration.embeddedSuite(Bug5054Test.class)) {
protected void decorateSQL(Statement stmt) throws SQLException {
stmt.executeUpdate("CREATE TABLE T1 (a integer, b integer)");
stmt.executeUpdate("INSERT INTO T1 VALUES(1, 1)");
stmt.executeUpdate("INSERT INTO T1 VALUES(2, 2)");
}
};
suite.addTest(test);
suite.addTest(TestConfiguration.clientServerDecorator(test));
return suite;
}
use of org.apache.derbyTesting.junit.CleanDatabaseTestSetup in project derby by apache.
the class XATest method baseSuite.
public static Test baseSuite(String name) {
BaseTestSuite suite = new BaseTestSuite(name);
suite.addTestSuite(XATest.class);
return new CleanDatabaseTestSetup(suite) {
/**
* Creates the table used in the test cases.
*/
protected void decorateSQL(Statement s) throws SQLException {
XATestUtil.createXATransactionView(s);
// Table for lock timeout test
s.executeUpdate("CREATE TABLE TABLT (I INT)");
s.executeUpdate("INSERT INTO TABLT VALUES(1)");
}
};
}
use of org.apache.derbyTesting.junit.CleanDatabaseTestSetup in project derby by apache.
the class UDAPermsTest method suite.
// /////////////////////////////////////////////////////////////////////////////////
//
// JUnit BEHAVIOR
//
// /////////////////////////////////////////////////////////////////////////////////
/**
* Construct top level suite in this JUnit test
*/
public static Test suite() {
BaseTestSuite suite = (BaseTestSuite) TestConfiguration.embeddedSuite(UDAPermsTest.class);
Test cleanTest = new CleanDatabaseTestSetup(suite);
Test authenticatedTest = DatabasePropertyTestSetup.builtinAuthentication(cleanTest, LEGAL_USERS, "udaPermissions");
Test authorizedTest = TestConfiguration.sqlAuthorizationDecorator(authenticatedTest);
return authorizedTest;
}
Aggregations