Re: ocl conformance test



Date view Thread view Subject view Author view Attachment view

From: Stefan Haustein (haustein@kimo.cs.uni-dortmund.de)
Date: Wed 11 Feb 2004 - 13:46:10 GMT


Jrn Guy S wrote:
> Of course you are right in that a conformance test suite would greatly improve quality 
 > and comparability among parsers/interpreters for OCL. The impediment here is 
that currently
 > no standardized interface to OCL parsers/interpreters is available, so no 
automatic compliance
 > testing can be performed. I have initiated an effort to develop such 
interface following UML2003,
 > but as of now there is almost no progress. IMHO, as long as there is no such 
interface,
 > comparability OCL parsers will not be achievable and thus implementation of 
such parsers
 > remains a scientific niche activity that does not yield reusable components. 
If you would like
 > to invest your time in a standardization effort, the results would probably 
make a great difference.

Hi Jrn,

as a starting point, why have not an XMI file describing a simple class and 
object diagram and an XML file with a set of test expressions:

<oclTest model="Test.xmi">
  <group name="Collection">
   <group name="Sets">
    <test>
     <expression>Set{3,2,2,1}</expression>
     <result>Set{1,2,3}</result>
    </test>
    <test>
     <expression>Set{3,2,1}-&gt;select(x|x>1)</expression>
     <result>Set{2,3}</result>
    </test>
   </group>
  </group>
</ocltest>

Support for this kind of tests is probably simple to implement on top of 
existing OCL tools. This would allow some shared basic tests without a 
standardized interface to the OCL parsers/interpreters,and I think it would be 
at least more useful than "nothing"?

Best regards,
Stefan Haustein

Date view Thread view Subject view Author view Attachment view