DirectedSparseGraph g = FsmParser.buildGraph(fsm, learnerName);
//Visualiser.updateFrame(g, null);Visualiser.waitForKey();
LearnerGraph s = new LearnerGraph(g, testConfig);
OrigStatePair pairOrig =
new OrigStatePair(
DeterministicDirectedSparseGraph.findVertex(JUConstants.LABEL, new VertexID("B"), g),
DeterministicDirectedSparseGraph.findVertex(JUConstants.LABEL, new VertexID("A"), g));
StatePair pairNew1 = new StatePair(s.findVertex(new VertexID("B")),s.findVertex(new VertexID("A")));
DirectedSparseGraph
temp = mergeAndDeterminize((Graph)g.copy(), pairOrig),
tempB = MergeStates.mergeAndDeterminize(g, pairNew1,testConfig);
// Now check that ComputeStateScores properly does mergeAndDeterminize
// (on the test data we are dealing with in these tests, there are separate tests for mergeAndDeterminize)
LearnerGraph tempG = new LearnerGraph(temp,testConfig), tempBG = new LearnerGraph(tempB,testConfig);
Assert.assertEquals(false, tempG.pathroutines.checkUnreachableStates());Assert.assertEquals(false, tempBG.pathroutines.checkUnreachableStates());
Assert.assertNull(WMethod.checkM(tempG, tempBG));
doneEdges = new HashSet<DirectedSparseEdge>();
int origScore = computeScore(g, pairOrig),
newScoreA = s.pairscores.computeStateScore(pairNew1),
newScoreB = s.pairscores.computePairCompatibilityScore(pairNew1),
newScoreC = s.pairscores.computePairCompatibilityScore_general(pairNew1, new LinkedList<AMEquivalenceClass<CmpVertex,LearnerGraphCachedData>>());
LearnerGraph learner2 = new LearnerGraph(g, testConfig);
StatePair pairNew2 = new StatePair(learner2.findVertex(new VertexID("B")),learner2.findVertex(new VertexID("A")));
//Visualiser.updateFrame(g, MergeStates.mergeAndDeterminize_general(learner2, pairNew2).pathroutines.getGraph(learnerName));Visualiser.waitForKey();
Collection<List<String>>
// Since computeQS assumes that red names remain unchanged in the merged version, I have to use a specific merging procedure
questionsB = ComputeQuestions.computeQS_orig(pairNew2, learner2,MergeStates.mergeAndDeterminize(learner2, pairNew2)),
questionsC = ComputeQuestions.computeQS_orig(pairNew2, learner2,MergeStates.mergeAndDeterminize_general(learner2, pairNew2)),