Apache JDO Project - [jira] Commented: (JDO-165) Implement new JDO 2 query tests cases concerning SQL queri

This is Interesting: Free IT Magazines  
Home > Archive > Apache JDO Project > November 2005 > [jira] Commented: (JDO-165) Implement new JDO 2 query tests cases concerning SQL queri





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author [jira] Commented: (JDO-165) Implement new JDO 2 query tests cases concerning SQL queri
Michael Bouschen (JIRA)

2005-11-23, 7:45 am

[ http://issues.apache.org/jira/brows...action_12358359 ]

Michael Bouschen commented on JDO-165:
--------------------------------------

Looks good. Some comments:

ShapeOfResult:
- I guess the "C" in the comment of the first two queries in VALID_SQL_QUERIES means candidate class, correct?
- At the first glance the code looks like you missed testing queries 3, 5, and 7. Then I figured out the test methods calls a method which calls another method which then executes two queries. I think the code would be easier if the test methods directly
execute the two SQL queries.

AllowedAPIMethods:
- Please add a comment to method testNegative describing that the SQL query is correct, but the test calls Query API method that are not allowed for SQL queries. Maybe rename checkSetters to checkProhibitedSetters.

QueryTests:
- Please add a sentence to the javadoc of method executeSQLQuery desribing that the sql parameter may have an argument {0} which is replaced by the current schema name.

> Implement new JDO 2 query tests cases concerning SQL queries.
> -------------------------------------------------------------
>
> Key: JDO-165
> URL: http://issues.apache.org/jira/browse/JDO-165
> Project: JDO
> Type: New Feature
> Components: tck20
> Reporter: Michael Watzek
> Assignee: Michael Watzek
> Attachments: JDO-165.patch
>
> We need 4 new test classes, one for each of the following assertions:
> - A14.7-1: In this case, the factory method that takes the language string and Object is used: newQuery (String language, Object query). The language parameter is javax.jdo.query.SQL and the query parameter is the SQL query string.
> - A14.7-2: The only methods that can be used are setClass to establish the candidate class, setUnique to declare that there is only one result row, and setResultClass to establish the result class.
> - A14.7-3: SQL queries can be defined without a candidate class. These queries can be found by name using the factory method newNamedQuery, specifying the class as null, or can be constructed without a candidate class.
> - A14.7-4: Table 7: Shape of Result of SQL Query.
> Details can be found on Wiki page http://wiki.apache.org/jdo/QueryTests#SQLQueries.


--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secur...nistrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira


Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com