Dresden OCL Toolkit

tudresden.ocl.test
Class TestInjection

java.lang.Object
  extended bytudresden.ocl.test.TestInjection
Direct Known Subclasses:
TestInjectionRoyloy

abstract class TestInjection
extends Object


Field Summary
private  ArrayList allobjects
          All objects.
private  HashSet ev
           
private  HashSet ev1
          Contains all expected constraint violations.
private  HashSet ev2
           
private  boolean strict
           
private  ArrayList violationsNow
           
 
Constructor Summary
protected TestInjection(boolean strict)
           
 
Method Summary
protected  void add(Object o)
           
protected  void assertAll()
           
protected  void assertNoViolationsNowLeft()
           
protected abstract  void doTest()
           
private  void ensureAllViolations()
           
private  void error(String m)
           
protected  void expectViolation(String m)
           
protected  void expectViolationNow(String violation)
           
 void onViolation(String m)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

strict

private boolean strict

allobjects

private ArrayList allobjects
All objects. Has to be a List, so that assertAll() always tests objects in the same order.


ev1

private HashSet ev1
Contains all expected constraint violations.


ev2

private HashSet ev2

ev

private HashSet ev

violationsNow

private final ArrayList violationsNow
Constructor Detail

TestInjection

protected TestInjection(boolean strict)
Method Detail

doTest

protected abstract void doTest()

add

protected final void add(Object o)

ensureAllViolations

private void ensureAllViolations()

assertAll

protected final void assertAll()

onViolation

public void onViolation(String m)

expectViolation

protected final void expectViolation(String m)

expectViolationNow

protected final void expectViolationNow(String violation)

assertNoViolationsNowLeft

protected final void assertNoViolationsNowLeft()

error

private void error(String m)

Dresden OCL Toolkit

Submit a bug
Developed at the Dresden University of Technology.
This software is published under the GNU Lesser General Public License.