Package org.emftrace.metamodel.EMFfitModel

Examples of org.emftrace.metamodel.EMFfitModel.Factor


public class DeleteFTEntryCommandTest extends EMFfitTestCase{

  @Test
  public void testDoRunForFactor(){
    FactorCategory fc1st  = (FactorCategory) factorTable.getEntries().get(0);
    Factor factor3rd = (Factor) fc1st.getChildren().get(2);
 
    new DeleteFTEntryCommand(factor3rd).runWithoutUnicaseCommand();
    assertEquals(3, fc1st.getChildren().size());
    assertEquals("O1.1", ((FactorCategory) fc1st.getChildren().get(0)).getNumbering());
    assertEquals("O1.2", ((Factor) fc1st.getChildren().get(1)).getNumbering());
View Full Code Here


    String term1Identifier = term1.getIdentifier();

    Link link = EMFfitModelFactory.eINSTANCE.createLink();
    link.setVisibleContent("link1");
    Factor linkedFactor = EMFfitModelFactory.eINSTANCE.createFactor();
    link.setTarget(linkedFactor);
    String linkIdentifier = link.getIdentifier();

    Term term2 = EMFfitModelFactory.eINSTANCE.createTerm();
    term2.setVisibleContent(" term2");
    String term2Identifier = term2.getIdentifier();

    oldHypertext.getContent().add(term1);
    oldHypertext.getContent().add(link);
    oldHypertext.getContent().add(term2);

    //setup for new changed hypertext element
    String newTerm1Content = "xxxterm1xxx xxx ";
    String newLinkContent = "newlink";
    String newTerm2Content = "xxxterm2xxx xxx";

    Hypertext newHypertext = EMFfitModelFactory.eINSTANCE.createHypertext();

    Term newTerm1 = EMFfitModelFactory.eINSTANCE.createTerm();
    newTerm1.setVisibleContent(newTerm1Content);

    Link newLink = EMFfitModelFactory.eINSTANCE.createLink();
    newLink.setVisibleContent(newLinkContent);
    Factor newLinkedFactor = EMFfitModelFactory.eINSTANCE.createFactor();
    newLink.setTarget(newLinkedFactor);

    Term newterm2 = EMFfitModelFactory.eINSTANCE.createTerm();
    newterm2.setVisibleContent(newTerm2Content);
View Full Code Here

  @Test
  public void testDoRun() {
    //setup
    RelatedIssue relatedIssue = issueCard.getRelatedIssues().get(0);
    Factor newFactor = EMFfitModelFactory.eINSTANCE.createFactor();
   
    //run command
    new SetRelatedIssueIssueCommand(relatedIssue, newFactor).runWithoutUnicaseCommand();
   
    //check
View Full Code Here

    for (int i = 0; i < size; i++) {
      m = modelElements.get(i);
      if (m instanceof IntentionalElement) {
        if (((IntentionalElement) m).getType() == IntentionalElementType.GOAL
            || ((IntentionalElement) m).getType() == IntentionalElementType.SOFTGOAL) {
          Factor factor = EMFfitModelFactory.eINSTANCE.createFactor();
          factor.setName(((IntentionalElement) m).getName());
          factor.setPriority("2");
          factor.setNumbering("P"
              + (factorTable.getEntries().size() + 1));
          factorTable.getEntries().add(factor);
          factor.setDescription(EMFfitModelFactory.eINSTANCE.createHypertext());
          factor.setChangeability(EMFfitModelFactory.eINSTANCE.createHypertext());
          factor.setFlexibility(EMFfitModelFactory.eINSTANCE.createHypertext());
          factor.setInfluence(EMFfitModelFactory.eINSTANCE.createHypertext());
        }
      }
    }

    return;
View Full Code Here

  @Test
  public void testDoRun() {
    //setup
    InfluencingFactor influencingFactor = issueCard.getInfluencingFactors().get(0);
    Factor newFactor = EMFfitModelFactory.eINSTANCE.createFactor();
   
    //run command
    new SetInfluencingFactorFactorCommand(influencingFactor, newFactor).runWithoutUnicaseCommand();
   
    //check
View Full Code Here

TOP

Related Classes of org.emftrace.metamodel.EMFfitModel.Factor

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.