ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 38245] - <sql> lacks any decent tests
Date Fri, 20 Jan 2006 10:54:28 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38245>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=38245





------- Additional Comments From stevel@apache.org  2006-01-20 11:54 -------
Pasting in Ken's todo list for the testss 
from the mailing list

Tests for "onError", "delimiter", "delimterType", "keepFormat" on either files
or embedded text are where I'd focus, I think, because they *are* platform
specific.  IIRC the history of this task correctly, all of those attributes were
added to support loading Oracle PL/SQL procedures and SQL/PLUS scripts.

"onError" is really subjective, depending on what you're executing - a table
drop before recreating it is standard procedure, but the "table or view does not
exist" *is* an error

Testing aside for the moment, this is one of the reasons that I think the
"decorator" idea has merit.  Let the JDBC class create the DB specific
decorator, or a generic pass through if no db is specified.  BWC is maintained
if the addition of the "decorator" is driven from YAA (yet another attribute).

Here's my suggestion:

0.  Convince my boss and my wife that this is really beneficial for the world at
large and is worth the investment of some work and leisure time. ;^)

1.  Develop base tests for current behavior using what ever is readily available
on Gump (sounds like HSQL and Derby), using DBUnit for basic CRUD testing
verification.  I think we should assume a schema, not including schema script
generation in the base tests of the SQL task.

2.  Refactor JDBC/SQL to allow for db specific decorators:
    * Extract the java interface to the SQL task.
    * Rename the existing SQL task to CoreSql or BaseSql, implementing the
interface.
    * Edit JDBC to invoke via I/F
    * Retest.

3.  Create a "pass-through" decorator, 100% delegation of all methods to the
CoreSql code.
    * Refactor SQL to use it.
    * Retest.

4.  Create HSQL and or Derby decorators.  Unfortunately, I don't know what I'd
put in these - my particular itch is around the Oracle specifics.

5.  Open the door for some "community" development/testing of the commercial
platforms.



-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message