Issue Details (XML | Word | Printable)

Key: JDO-320
Type: Test Test
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Erik Bengtson
Reporter: Michael Bouschen
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
JDO

Add negative query test for projecting a map and collection field to tck20

Created: 26/Feb/06 07:38 AM   Updated: 15/Mar/06 06:33 AM
Return to search
Component/s: tck2
Affects Version/s: JDO 2 rc1
Fix Version/s: JDO 2 final

Time Tracking:
Not Specified

File Attachments:
  Size
Text File Licensed for inclusion in ASF works JDO-320.patch 2006-03-03 06:23 AM Michael Bouschen 2 kB

Resolution Date: 15/Mar/06 06:33 AM


 Description  « Hide
The latest version of the JDO spec disallows JDOQL queries projecting a collection or map field, e.g.
  SELECT p.phoneNumbers FROM org.apache.jdo.tck.pc.company.Person p
  SELECT d.employees FROM org.apache.jdo.tck.pc.company.Department d
We should add a test method running the above queries which should result in a JDOException.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Michael Bouschen added a comment - 03/Mar/06 06:23 AM
Attached you find a patch JDO-320.patch for review. It adds the two negative test queries to the ResultExpressions class.

Please note, that the current JPOX version currently accepts JDOQL queries returning a collection field, so the negative test fails.

Michael Bouschen made changes - 03/Mar/06 06:23 AM
Field Original Value New Value
Attachment JDO-320.patch [ 12323643 ]
Craig Russell added a comment - 03/Mar/06 01:20 PM
Looks good.

Repository Revision Date User Message
ASF #383191 Sat Mar 04 19:51:17 UTC 2006 mbo JDO-320: Add negative query test for projecting a map and collection field to tck20
Files Changed
MODIFY /db/jdo/trunk/tck20/src/java/org/apache/jdo/tck/query/result/ResultExpressions.java

Michael Bouschen added a comment - 05/Mar/06 04:57 AM
Checked in the patch which adds two negative test queries to class org.apache.jdo.tck.query.result.ResultExpressions (see revision 383191).

Assigning the issue to Erik, becaue the current JPOX version allows projection of collection and map fields, so the negative tests fail.

Michael Bouschen made changes - 05/Mar/06 04:57 AM
Assignee Michael Bouschen [ mbo ] Erik Bengtson [ ebengtso ]
Erik Bengtson added a comment - 08/Mar/06 05:33 PM
should be fixed in JPOX CVS now

Craig Russell added a comment - 15/Mar/06 06:33 AM
Fixed with the latest JPOX build.

Craig Russell made changes - 15/Mar/06 06:33 AM
Status Open [ 1 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]