createPriorizedDecomposition(gssQuery, d2, 0);
createPriorizedDecomposition(gssQuery, d4, 0);
PrioritizedElement selectedGoal1 = createSelectedGoal(gssQuery, g1, 0);
PrioritizedElement selectedGoal2 = QueryFactory.eINSTANCE.createPrioritizedElement();
selectedGoal2.setElement(g2);
PrioritizedElement selectedGoal3 = createSelectedGoal(gssQuery, g3, 0);
PrioritizedElement selectedGoal4 = createSelectedGoal(gssQuery, g4, 0);
List<Decomposition> outgoingDecompositions = new ArrayList<Decomposition>();
List<Decomposition> incomingDecompositions = new ArrayList<Decomposition>();
incomingDecompositions.add(d3);
outgoingDecompositions.add(d1);
new AddPrioritizedElementCommand(gssQuery.getSelectedGoalsSet(), selectedGoal2, outgoingDecompositions, incomingDecompositions).runWithoutUnicaseCommand();
incomingDecompositions.clear();
outgoingDecompositions.clear();
outgoingDecompositions.add(d3);
outgoingDecompositions.add(d4);
PrioritizedElement selectedGoal4clone = QueryFactory.eINSTANCE.createPrioritizedElement();
selectedGoal4clone.setElement(g4);
new AddPrioritizedElementCommand(gssQuery.getSelectedGoalsSet(), selectedGoal4clone, outgoingDecompositions, incomingDecompositions).runWithoutUnicaseCommand();
assertEquals(4, gssQuery.getSelectedGoalsSet().getPrioritizedElements().size());