-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: How to UnitTest when dealing with sequence ID
PostPosted: Wed Aug 18, 2004 12:09 pm 
Newbie

Joined: Fri Aug 13, 2004 12:17 pm
Posts: 12
Location: St. Louis, MO
What is the best way to write a unit test for save/load operations when your id is generated via a sequence?


Top
 Profile  
 
 Post subject: Re: How to UnitTest when dealing with sequence ID
PostPosted: Wed Aug 18, 2004 5:23 pm 
Proxool Developer
Proxool Developer

Joined: Tue Aug 26, 2003 10:42 am
Posts: 373
Location: Belgium
ryan.tyer wrote:
What is the best way to write a unit test for save/load operations when your id is generated via a sequence?


If you don't have control over your (system) ids, then you should have business keys. Use them or whatever other criteria to find your data back.

Anyway, ask yourself how you would find your data back from within your application and do the same in your tests.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.