PHPUnit Database Testing PHPUnit Database Testing database database

PHPUnit Database Testing


According to

this is already built-in.

Also see these slides by M.Lively (the main DBUnit author)

and B. Eberlei's Ultimate Guide to DB Testing with PHPUnit

So it should work along the lines of

$database_dataset = new PHPUnit_Extensions_Database_DataSet_DataSetFilter (     $this->getConnection()->createDataSet(array('bank_account')),     array('bank_account' => array ('date_created')) // excluded);