Package org.emftrace.metamodel.QUARCModel.Constraints

Examples of org.emftrace.metamodel.QUARCModel.Constraints.IntegerTechnicalProperty


 
 
  @Test
  public void testIntegerTechnicalProperty() {
    IntegerTechnicalProperty property = ConstraintsFactory.eINSTANCE.createIntegerTechnicalProperty();
   
   
    assertNull(ConstraintValueValidator.validateValue("1",property));
    assertNull(ConstraintValueValidator.validateValue("-1",property));
    assertNotNull(ConstraintValueValidator.validateValue("1.1",property));
    assertNotNull(ConstraintValueValidator.validateValue("-1.1",property));
    assertNotNull(ConstraintValueValidator.validateValue("-0.1",property));
    assertNotNull(ConstraintValueValidator.validateValue("0.1",property));
    assertNotNull(ConstraintValueValidator.validateValue("0.0.0",property));
    assertNotNull(ConstraintValueValidator.validateValue("--1",property));
   
    property.setMax("5");
    property.setMin("1");
   
    assertNull(ConstraintValueValidator.validateValue("1",property));
    assertNull(ConstraintValueValidator.validateValue("5",property));

    assertNotNull(ConstraintValueValidator.validateValue("6",property));
View Full Code Here

TOP

Related Classes of org.emftrace.metamodel.QUARCModel.Constraints.IntegerTechnicalProperty

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.