DbC with Jtest
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   srikanth_Nittala
Posted On:   Friday, July 30, 2004 11:55 AM

Hi , I am using Jtest as the unit testing tool for my project.Now in the process ,i am planning to use design by contract language which Jtest supports.But to use it i have a big question in my mind.How does the DBC specifications affect my coding? I mean if i say, in the precondition some (object != null) and some (object.attribute > 50) , do i need to again validate for these in the code ? Well lets say it does not make sense because Jtest will process the DBC and verifies these things.But when my code goes to production,there will not be anyone to check on these things and if such a kind of bad input comes, my code will not work right ? Its something like sailing without life jacket! So in a gist my questions would be a)At what point o   More>>

Hi ,
I am using Jtest as the unit testing tool for my project.Now in the process ,i am planning to use design by contract language which Jtest supports.But to use it i have a big question in my mind.How does the DBC specifications affect my coding? I mean if i say, in the precondition some (object != null) and some (object.attribute > 50) , do i need to again validate for these in the code ? Well lets say it does not make sense because Jtest will process the DBC and verifies these things.But when my code goes to production,there will not be anyone to check on these things and if such a kind of bad input comes, my code will not work right ? Its something like sailing without life jacket!
So in a gist my questions would be
a)At what point of coding is the DBC used ? Can it be used in Maintenance/enhancements ?
b) And does using the DBC help in reducing coding efforts like validations e.t.c(I mean does the same pre-condition need to be validated again in the code ).
Kindly guide me.

   <<Less
About | Sitemap | Contact