Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » OCL » Extra pivot model testing
Extra pivot model testing [message #650471] Tue, 25 January 2011 02:13
Ed Willink is currently offline Ed Willink
Messages: 4035
Registered: July 2009
Senior Member
Hi

The org.eclipse.ocl.examples.test.xtext.SerializeTests tests assert that
a variety of Ecore models in org.eclipse.ocl.examples.test.xtext.models
can be successfully converted:

Ecore->Pivot->OCLinEcore then OCLinEcore->Pivot->Ecore to produce what
EMF Compare considers to be the same model.

There are currently three known limitations:
- OCL text is pretty-printed so whitespace changes are reported.
- Upper and lower bounds on generic types are not supported.
- Multiplicity upperbound of -2 (mixed content) is not supported.
- Hidden opposites (untested) might make it forwards but not backwards

EReference.eKeys might work, but I have no example.

If you have any potentially challenging Ecore models, please run them
by adapting my extra SerializeTests below.

-----------------

package org.eclipse.ocl.examples.test.xtext;

/**
* Tests that check that an Ecore model can be serialized to OCLinEcore.
*/
public class SerializeTests2 extends SerializeTests
{
public void testTemp() throws Exception {
doSerialize("temp");
}
public void testTemp3() throws Exception {
doSerialize("Temp3");
}
public void testTemp4() throws Exception {
doSerialize("Temp4");
}
public void testMy() throws Exception {
doSerialize("My");
}
}

-----------------

You may want to wait till M5 to avoid the difficulties of piecing the
Xtext M4.5 contributions together.

Any 'good' failures I'd like to add to the test suite.

Regards

Ed Willink
Previous Topic:[Announce] MDT/OCL 3.1.0 M4 is now available
Next Topic:[Announce] MDT/OCL 3.1.0 M5 is now available
Goto Forum:
  


Current Time: Sun Aug 31 00:41:46 EDT 2014

Powered by FUDForum. Page generated in 0.01526 seconds