Package org.apache.derbyTesting.junit

Examples of org.apache.derbyTesting.junit.CleanDatabaseTestSetup


     * Run only in embedded as TRIGGERs are server side logic.
     * Also the use of a ThreadLocal to check state requires
     * embedded.
     */
    public static Test suite() {
        return new CleanDatabaseTestSetup(
                TestConfiguration.embeddedSuite(TriggerTest.class));
       
    }
View Full Code Here


  private static Test getSuite(String[] list)
  {
        TestSuite suite = new TestSuite("SQL scripts");
        for (int i = 0; i < list.length; i++)
            suite.addTest(
                new CleanDatabaseTestSetup(
                new LangScripts(list[i])));

        return getIJConfig(suite);
    }
View Full Code Here

  protected static Test baseSuite(String name) {
          TestSuite suite = new TestSuite(name);
          suite.addTestSuite(ReleaseCompileLocksTest.class);
         
    return new CleanDatabaseTestSetup(suite)
          {
                protected void decorateSQL(Statement s) throws SQLException
                {
        s.execute("create table t1 (s int)")
                }
View Full Code Here

    public static Test baseSuite(String name) {
        TestSuite suite = new TestSuite(name);
        suite.addTestSuite(NullIfTest.class);

        return new CleanDatabaseTestSetup(suite) {
            /**
             * Creates the table used in the test cases.
             *
             */
            protected void decorateSQL(Statement s) throws SQLException {
View Full Code Here

    }

    public static Test suite() {
        TestSuite suite = new TestSuite("AnsiTrimTest");
        suite.addTestSuite(AnsiTrimTest.class);
        return new CleanDatabaseTestSetup(suite) {
            public void decorateSQL(Statement s)
                    throws SQLException {
                s.executeUpdate("create table tt (id int, v varchar(16), c char(16), cl clob(10240))");
                s.executeUpdate("insert into tt values (1, 'abcaca', 'abcaca', 'abcaca')");
                s.executeUpdate("create table nt (v varchar(2))");
View Full Code Here

        }

        suite.addTestSuite(AutoGenJDBC30Test.class);

        // Create database objects only once for entire test run
        return new CleanDatabaseTestSetup(suite)
        {
            /**
            * Creates the database objects used in the test cases.
            * @throws SQLException
            */
 
View Full Code Here

    }

    private static Test baseSuite(String name) {
        TestSuite testSuite = new TestSuite(name);
        testSuite.addTestSuite(TestDbMetaData.class);
        return new CleanDatabaseTestSetup(testSuite) {
                protected void decorateSQL(Statement s) throws SQLException {
                    createFunctions(s);
                }
            };
    }
View Full Code Here

    public static Test suite()
    {
        if (Derby.hasTools()) {
            TestSuite suite = new TestSuite("IJRunScriptTest");
            suite.addTestSuite(IJRunScriptTest.class);
            return new CleanDatabaseTestSetup(suite);
        }
       
        return new TestSuite("empty: no tools support");
    }
View Full Code Here

  public OLAPTest(String name) {
    super(name);   
  }

  public static Test makeSuite() {
        Test clean = new CleanDatabaseTestSetup(
            new TestSuite(OLAPTest.class)) {
                protected void decorateSQL(Statement s)
                        throws SQLException
                {
                    getConnection().setAutoCommit(false);
View Full Code Here

    public static Test baseSuite(String name) {

        TestSuite suite = new TestSuite(name);
        suite.addTestSuite(LargeDataLocksTest.class);

        return new CleanDatabaseTestSetup(suite) {

            /**
             * Create and populate table
             *
             * @see org.apache.derbyTesting.junit.CleanDatabaseTestSetup#decorateSQL(java.sql.Statement)
View Full Code Here

TOP

Related Classes of org.apache.derbyTesting.junit.CleanDatabaseTestSetup

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.