Hello Kay,

>> Generally, this looks correct for using EMF without the Eclipse
>> infrastructure.  It is preferrable to write code like that in the form
>> of a unit test, though.  
> Yes. But does unit testing not rely on knowledge of the expected outcome from 
> the SUT to check the real one against?
> It was just a starting point, a prototype, a 'feasability study' to find out 
> if 
> I'm able to handle a reqif file without ProR. I didn't know what to expect.

You're certainly right with your reply.  This was just a recommendation,
and has little to do with your "real" question.

But since you asked, let me elaborate: Because your code contained four
"tests" (albeit without asserts), it feels natural to wrap them in unit
tests.  You have an implicit assert: Running the test must not throw an
Exception.  Rewriting it as a unit tests makes development a lot easier:
You immediate see the results of the four test cases, and if an
Exception is thrown, the test is marked as failed.  You also see the
stack trace directly in Eclipse, and run just one test alone. 

> Put it into the test suite, please :-)

... And of course, that is another reason for confirming a bug with a
test: Once added to the test suite, this problem will never pop up again
without us noticing.  Yes, I was planning on adding it.

Hope this helps!

Best,

- Michael


-- 
*Michael Jastram*       +49 (162) 274 83 94     http://jastram.de
Geschäftsführer         Formal Mind GmbH        http://formalmind.com
Wissenschaftler         Heinrich Heine Universität Düsseldorf
http://www.stups.uni-duesseldorf.de
<http://www.stups.uni-duesseldorf.de/w/Michael_Jastram>
Vorsitzender    rheinjug e.V.   http://rheinjug.de
Project Lead    Eclipse Requirements Modeling Framework
http://eclipse.org/rmf

_______________________________________________
rmf-dev mailing list
rmf-dev@eclipse.org
http://dev.eclipse.org/mailman/listinfo/rmf-dev

Reply via email to