Package org.emftrace.metamodel.QUARCModel.GSS

Examples of org.emftrace.metamodel.QUARCModel.GSS.Principle


    // build graph for test case
    Goal g1 = createGoal(gss, 1);
    Goal g2 = createGoal(gss, 2);
    Goal g3 = createGoal(gss, 3);
   
    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);
    Principle p3 = createPrinciple(gss, 3);
    Principle p4 = createPrinciple(gss, 4);
    Principle p5 = createPrinciple(gss, 5);
    Principle p6 = createPrinciple(gss, 6);
    Principle p7 = createPrinciple(gss, 7);


    createDecomposition(gss, g2, g1);
    createDecomposition(gss, g3, g1);
    createDecomposition(gss, p3, p1);
View Full Code Here


    // build graph for test case
    Goal g1 = createGoal(gss, 1);
    Goal g2 = createGoal(gss, 2);
    Goal g3 = createGoal(gss, 3);
   
    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);
    Principle p3 = createPrinciple(gss, 3);
    Principle p4 = createPrinciple(gss, 4);
    Principle p5 = createPrinciple(gss, 5);
    Principle p6 = createPrinciple(gss, 6);
    Principle p7 = createPrinciple(gss, 7);
    Principle p8 = createPrinciple(gss, 8);
    Principle p9 = createPrinciple(gss, 9);

    createDecomposition(gss, g2, g1);
    createDecomposition(gss, g3, g1);
    createDecomposition(gss, p3, p1);
    createDecomposition(gss, p4, p1);
View Full Code Here

    // build graph for test case
   
    Goal g1 = createGoal(gss, 1);
   
    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);
    Principle p3 = createPrinciple(gss, 3);

    createDecomposition(gss, p3, p1);
    createDecomposition(gss, p3, p2);
   
    createImpact(gss, p1, g1, 50.0f);
View Full Code Here

  @Test
  public void testNoPreconditionsFromParents() {
    Goal g1 = createGoal(gss, 1);

    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);

    Pattern si1 = createPattern(gss, 1);
    Pattern si2 = createPattern(gss, 2);

    createDecomposition(gss, p2, p1);
View Full Code Here

  @Test
  public void testPreconditionsFromParents1() {
    Goal g1 = createGoal(gss, 1);

    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);

    Pattern si1 = createPattern(gss, 1);
    Pattern si2 = createPattern(gss, 2);

    TechnicalProperty propery = ConstraintsFactory.eINSTANCE
View Full Code Here

  @Test
  public void testPreconditionsFromParents2() {
    Goal g1 = createGoal(gss, 1);

    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);
    Principle p3 = createPrinciple(gss, 3);

    Pattern si1 = createPattern(gss, 1);

    TechnicalProperty propery1 = ConstraintsFactory.eINSTANCE
        .createStringTechnicalProperty();
    propery1.setName("foo");
    Precondition precondition1 = ConstraintsFactory.eINSTANCE
        .createPrecondition();
    BaseCondition baseCondition1 = ConstraintsFactory.eINSTANCE
        .createBaseCondition();
    baseCondition1.setTechnicalProperty(propery1);
    baseCondition1.setValue("true");
    baseCondition1.setOperator(BaseConditionOperators.EQUALS);
    precondition1.getBaseConditions().add(baseCondition1);
    p2.setPrecondition(precondition1);

    TechnicalProperty propery2 = ConstraintsFactory.eINSTANCE
        .createStringTechnicalProperty();
    propery2.setName("bar");
    Precondition precondition2 = ConstraintsFactory.eINSTANCE
        .createPrecondition();
    BaseCondition baseCondition2 = ConstraintsFactory.eINSTANCE
        .createBaseCondition();
    baseCondition2.setTechnicalProperty(propery2);
    baseCondition2.setValue("false");
    baseCondition2.setOperator(BaseConditionOperators.EQUALS);
    precondition2.getBaseConditions().add(baseCondition2);
    p3.setPrecondition(precondition2);

    createDecomposition(gss, p2, p1);
    createDecomposition(gss, p3, p1);

    createImpact(gss, p1, g1, 1);
View Full Code Here

  @Test
  public void testNoPrecondition() {
    Goal g1 = createGoal(gss, 1);

    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);

    Pattern si1 = createPattern(gss, 1);
    Pattern si2 = createPattern(gss, 2);

    createDecomposition(gss, p2, p1);

    createImpact(gss, p1, g1, 1);
    createImpact(gss, si1, p2, 1);
    createImpact(gss, si2, p1, 1);

    executeRequiredPhases();

    assertEquals("",
        PreconditionFinder.formatConditionString(si1.getPrecondition()));
    assertEquals("",
        PreconditionFinder.formatConditionString(si2.getPrecondition()));
    assertEquals("",
        PreconditionFinder.formatConditionString(p1.getPrecondition()));
    assertEquals("",
        PreconditionFinder.formatConditionString(p2.getPrecondition()));
  }
View Full Code Here

  @Test
  public void testPrecondition() {
    Goal g1 = createGoal(gss, 1);

    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 1);

    Pattern si1 = createPattern(gss, 1);
    Pattern si2 = createPattern(gss, 2);

    createDecomposition(gss, p2, p1);
View Full Code Here

  @Test
  public void testForGetRequirementsFromParentBug() {
    Goal g1 = createGoal(gss, 1);

    Principle p1 = createPrinciple(gss, 1);
    Principle p2 = createPrinciple(gss, 2);

    Principle p3 = createPrinciple(gss, 3);
    Principle p4 = createPrinciple(gss, 4);
    Principle p5 = createPrinciple(gss, 5);

    Pattern si1 = createPattern(gss, 1);
    Pattern si2 = createPattern(gss, 2);

    createDecomposition(gss, p2, p1);
View Full Code Here

  @Test
  public void testSimpleGraph() {

    Goal g1 = createGoal(gss, 1);

    Principle p1 = createPrinciple(gss, 1);
    Pattern si1 = createPattern(gss, 1);

    createImpact(gss, p1, g1, 1);
    createImpact(gss, si1, p1, 1);
View Full Code Here

TOP

Related Classes of org.emftrace.metamodel.QUARCModel.GSS.Principle

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.