Daniel Rall wrote:
Woo, more tests!
[EMAIL PROTECTED] wrote: ...
public class SQLToAppDataTest extends TestCase
{
/**
* Class to test for void SQLToAppData(String, String)
*/
public void testMySql() throws Exception
{
SQLToAppData sqlToAppData = new SQLToAppData(
"src/test/org/apache/torque/engine/database/transform/mysql.sql",
"mysql");
Database db = sqlToAppData.execute();
assertTrue(db.getTables().size() > 0);
Table course = db.getTable("course");
assertTrue(course != null);
The above two lines could be written as:
assertNotNull(db.getTable("course"));
right .. but there will be more tests using the table soon ;-)
Nice. ;-)
You could still take advatage of the easily human-readable assertNotNull() API, as opposed to inlining the null check and calling assertTrue().
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
