  @Test
  public void testExecute() throws Exception {

    // set up
    final DatabaseMeta dbMeta = context.mock(DatabaseMeta.class);
    context.checking(new Expectations() {
      {
        one(dbMeta).getName();
        will(returnValue(""));
        one(dbMeta).getXML();
        will(returnValue(null));
        allowing(dbMeta).getURL();
        will(returnValue("jdbc:hsqldb:mem:test"));
        one(dbMeta).getUsername();
        will(returnValue("sa"));
        one(dbMeta).getPassword();
        will(returnValue(""));
        one(dbMeta).getDriverClass();
        will(returnValue("org.hsqldb.jdbcDriver"));
      }
    });

    SchemaStub schemaStub = new SchemaStub();
    schemaStub.setDialect(new DialectStub());
    connectionModel.setSchema(schemaStub);
    
    exec.setConnectionModel(connectionModel);
    getConnectionModel().setDatabaseMeta(dbMeta);
    executionCompleteCalled = false;
    exec.execute(new String[]{"", ""}, new ExecutorCallback() {

      public void executionComplete(Exception e) {
        if (logger.isDebugEnabled()) {
          logger.debug("execution complete");
        }
        executionCompleteCalled = true;
      }

    });
    assertTrue("Execution complete not called.", executionCompleteCalled);
  }