title: dbunit test fails with NoSuchTableException, but table exists
body: <h1>Error</h1>
  
  <pre><code>java org.junit.runner.JUnitCore TestCase
  JUnit version 4.10
  .E..
  Time: 0.28
  There was 1 failure:
  1) testDbNoChanges(TestCase)
  org.dbunit.dataset.NoSuchTableException: Did not find table 'EVENTS' in schema 'null'
  </code></pre>
  
  <h1>Question</h1>
  
  <p>What does this error mean? What am I doing wrong? Why is the schema null?</p>
  
  <p>The second test, that actually tests a table, passes. This test, which is supposed to just test the database, fails. The tables all exist before and after.</p>
  
  <pre><code>mysql&gt; show tables;
  +---------------+
  | Tables_in_cal |
  +---------------+
  | events        |
  | guests        |
  | test          |
  +---------------+
  3 rows in set (0.00 sec)
  </code></pre>
  
  <h1>Source</h1>
  
  <p>I believe this is the useful snippet, but everything is at <a href="https://bitbucket.org/djeikyb/simple_dbunit" rel="nofollow">https://bitbucket.org/djeikyb/simple_dbunit</a></p>
  
  <pre><code> 36 public class TestCase
   37 {
   38 
   39   private IDatabaseTester database_tester;
   40 
   41 
   42   public IDataSet getDataSet() throws FileNotFoundException, DataSetException
   43   {
   44     return new FlatXmlDataSetBuilder().build(
   45         /*
   46         new FileInputStream("src/simple_dbunit/expected_dataset.xml"));
   47         new FileInputStream("dataset.xml"));
   48          */
   49         new FileInputStream("dataset.xml"));
   50   }
   51 
   52 
   53   @Before
   54   public void setUp() throws Exception
   55   {
   56     database_tester = new JdbcDatabaseTester("com.mysql.jdbc.Driver",
   57                                             "jdbc:mysql://localhost/cal",
   58                                             "cal",
   59                                             "cal");
   60     database_tester.setDataSet(getDataSet());
   61     database_tester.onSetup();
   62   }
   63 
   64   @Test
   65   public void testDbNoChanges() throws Exception
   66   {
   67     // expected
   68     IDataSet expected_data_set = getDataSet();
   69 
   70     // actual
   71     IDatabaseConnection connection = database_tester.getConnection();
   72     IDataSet actual_data_set = connection.createDataSet();
   73 
   74     // test
   75     Assertion.assertEquals(expected_data_set, actual_data_set);
   76   }
   77 
   78   @Test
   79   public void testTableNoChanges() throws Exception
   80   {
   81     // expected
   82     ITable expected_table = getDataSet().getTable("test");
   83 
   84     // actual
   85     IDatabaseConnection connection = database_tester.getConnection();
   86     IDataSet actual_data_set = connection.createDataSet();
   87     ITable actual_table = actual_data_set.getTable("test");
   88 
   89     // test
   90     Assertion.assertEquals(expected_table, actual_table);
   91   }
   92 
   93   @Test
   94   public void testTableNoChanges1() throws Exception
   95   {
   96     // expected
   97     ITable expected_table = getDataSet().getTable("test");
   98 
   99     // actual
  100     IDatabaseConnection connection = database_tester.getConnection();
  101     IDataSet actual_data_set = connection.createDataSet();
  102     ITable actual_table = actual_data_set.getTable("test");
  103 
  104     // test
  105     Assertion.assertEquals(expected_table, actual_table);
  106   }
  107 
  108 }
  </code></pre>