Package org.emftrace.metamodel.EMFfitModel

Examples of org.emftrace.metamodel.EMFfitModel.Factor


  public void testDoRunForMiddelOfWord(){

    Term term = EMFfitModelFactory.eINSTANCE.createTerm();
    term.setVisibleContent("foolinkbar");
    hyperText.getContent().add(term);
    Factor target = EMFfitModelFactory.eINSTANCE.createFactor();
   
   
    new DoHypertextLinkWordCommand(hyperText, 3, 4,"link", target).runWithoutUnicaseCommand();
   
   
View Full Code Here


   
    Term term1 = EMFfitModelFactory.eINSTANCE.createTerm();
    term1.setVisibleContent("foo ");
    hyperText.getContent().add(term1);
   
    Factor target1 = EMFfitModelFactory.eINSTANCE.createFactor();
    Link link1 = EMFfitModelFactory.eINSTANCE.createLink();
    link1.setVisibleContent("link1");
    link1.setTarget(target1);
    hyperText.getContent().add(link1);
   
    Term term2 = EMFfitModelFactory.eINSTANCE.createTerm();
    term2.setVisibleContent(" bar ");
    hyperText.getContent().add(term2);
   
    Factor target2 = EMFfitModelFactory.eINSTANCE.createFactor();
    Link link2 = EMFfitModelFactory.eINSTANCE.createLink();
    link2.setVisibleContent("link2");
    link2.setTarget(target2);
    hyperText.getContent().add(link2);
   

    Term term3 = EMFfitModelFactory.eINSTANCE.createTerm();
    term3.setVisibleContent(" foo newlink bar");
    hyperText.getContent().add(term3);

   
   
    Factor target3 = EMFfitModelFactory.eINSTANCE.createFactor();
    new DoHypertextLinkWordCommand(hyperText, 16, 7, "newlink",target3).runWithoutUnicaseCommand();
   
   
    //content must be [Term, Link, Term, Link, Term, Link, Term]
   
View Full Code Here

  public void testDoRunForLinkAtStart(){

    Term term = EMFfitModelFactory.eINSTANCE.createTerm();
    term.setVisibleContent("link foo");
    hyperText.getContent().add(term);
    Factor target = EMFfitModelFactory.eINSTANCE.createFactor();
 

    new DoHypertextLinkWordCommand(hyperText, 0, 4,"link", target).runWithoutUnicaseCommand();

   
View Full Code Here

  public void testDoRunForLinkAtEnd(){

    Term term = EMFfitModelFactory.eINSTANCE.createTerm();
    term.setVisibleContent("foo link");
    hyperText.getContent().add(term);
    Factor target = EMFfitModelFactory.eINSTANCE.createFactor();
   
   

    new DoHypertextLinkWordCommand(hyperText, 4, 4, "link",target).runWithoutUnicaseCommand();
   
View Full Code Here

  public void testDoRunForTerm(){

    Term term = EMFfitModelFactory.eINSTANCE.createTerm();
    term.setVisibleContent("link");
    hyperText.getContent().add(term);
    Factor target = EMFfitModelFactory.eINSTANCE.createFactor();
   
   

    new DoHypertextLinkWordCommand(hyperText, 0, 4, "link",target).runWithoutUnicaseCommand();
   
View Full Code Here

    accessLayer = new AccessLayer(false);
    accessLayer.registerProjectSpace(projectSpace);
   

   
    Factor factor1 = EMFfitModelFactory.eINSTANCE.createFactor();

    factor1.setName("foo factor 1");
    factor1.setDescription(HypertextHelpers.strToHypertext("I'm a description."));
    factor1.setFlexibility(HypertextHelpers.strToHypertext("I'm a flexibility."));
    factor1.setChangeability(HypertextHelpers.strToHypertext("I'm a changeabiliy."));
    factor1.setInfluence(HypertextHelpers.strToHypertext("I'm a influence."));
    factor1.setPriority("2");
   
    Factor factor2 = EMFfitModelFactory.eINSTANCE.createFactor();
    factor2.setName("foo factor 2");
    factor2.setDescription(HypertextHelpers.strToHypertext("I'm a description."));
    factor2.setFlexibility(HypertextHelpers.strToHypertext("I'm a flexibility."));
    factor2.setChangeability(HypertextHelpers.strToHypertext("I'm a changeabiliy."));
    factor2.setInfluence(HypertextHelpers.strToHypertext("I'm a influence."));
    factor2.setPriority("2");
   
    Factor factor3 = EMFfitModelFactory.eINSTANCE.createFactor();
    factor3.setName("foo factor 3");
    factor3.setDescription(HypertextHelpers.strToHypertext("I'm a description."));
    factor3.setFlexibility(HypertextHelpers.strToHypertext("I'm a flexibility."));
    factor3.setChangeability(HypertextHelpers.strToHypertext("I'm a changeabiliy."));
    factor3.setInfluence(HypertextHelpers.strToHypertext("I'm a influence."));
    factor3.setPriority("2");
   
    Factor factor4 = EMFfitModelFactory.eINSTANCE.createFactor();
    factor4.setName("foo factor 3");
    factor4.setDescription(HypertextHelpers.strToHypertext("I'm a description."));
    factor4.setFlexibility(HypertextHelpers.strToHypertext("I'm a flexibility."));
    factor4.setChangeability(HypertextHelpers.strToHypertext("I'm a changeabiliy."));
    factor4.setInfluence(HypertextHelpers.strToHypertext("I'm a influence."));
    factor4.setPriority("2");
   
    Factor factor5 = EMFfitModelFactory.eINSTANCE.createFactor();
   
    FactorCategory fc1 = EMFfitModelFactory.eINSTANCE.createFactorCategory();
    fc1.setName("foo category");
    fc1.setNumbering("O1");
   
View Full Code Here

    assertNotNull(issueCard.getRelatedIssues().get(3).getDescription());
  }
 
  @Test
  public void testDoRunForNonNullItem() {
    Factor factor = EMFfitModelFactory.eINSTANCE.createFactor();
    new NewIssueCardRelatedIssueCommand(issueCard, factor).runWithoutUnicaseCommand();
    assertEquals(4, issueCard.getRelatedIssues().size());
    assertEquals(factor, issueCard.getRelatedIssues().get(3).getIssue());
    assertNotNull(issueCard.getRelatedIssues().get(3).getDescription());
    assertEquals(project, ModelUtil.getProject(issueCard.getRelatedIssues().get(3).getIssue()));
View Full Code Here

  @Test
  public void testDoRun() {   
    new NewFactorTableFactorCommand(factorTable, "new foo factor", "2").runWithoutUnicaseCommand();
    assertEquals(3, factorTable.getEntries().size());
    Factor newFactor = (Factor) factorTable.getEntries().get(2);
    assertEquals("new foo factor", newFactor.getName());
    assertEquals("O3", newFactor.getNumbering());
    assertEquals("2", newFactor.getPriority());
    assertNotNull(newFactor.getDescription());
    assertNotNull(newFactor.getFlexibility());
    assertNotNull(newFactor.getChangeability());
    assertNotNull(newFactor.getInfluence());
  }
View Full Code Here

    Hypertext newChangeability = EMFfitModelFactory.eINSTANCE.createHypertext();
    Term term = EMFfitModelFactory.eINSTANCE.createTerm();
    term.setVisibleContent(content);
    newChangeability.getContent().add(term);
   
    Factor factor = (Factor)((FactorCategory)factorTable.getEntries().get(1)).getChildren().get(0);
   
    //run command
    new UpdateFactorChangeabilityCommand(factor,newChangeability ).runWithoutUnicaseCommand();
   
    //check results
    assertEquals(1, factor.getChangeability().getContent().size());
    assertEquals(content, ((Term)factor.getChangeability().getContent().get(0)).getVisibleContent());
  }
View Full Code Here

    Hypertext newChangeability = EMFfitModelFactory.eINSTANCE.createHypertext();
    Term term = EMFfitModelFactory.eINSTANCE.createTerm();
    term.setVisibleContent(content);
    newChangeability.getContent().add(term);
   
    Factor factor = (Factor)((FactorCategory)factorTable.getEntries().get(1)).getChildren().get(0);
    factor.setChangeability(null);
   
    //run command
    new UpdateFactorChangeabilityCommand(factor,newChangeability ).runWithoutUnicaseCommand();
   
    //check results
    assertEquals(1, factor.getChangeability().getContent().size());
    assertEquals(content, ((Term)factor.getChangeability().getContent().get(0)).getVisibleContent());
  }
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.