protected void checkGraphEquality(LearnerGraph what, LearnerGraph with) {
    DifferentFSMException ex = null;
    if (compareInDepth) {
      // if (!what.equals(with))
      //	ex = new DifferentFSMException("machines differ");
      ex = WMethod.checkM_and_colours(what, with, VERTEX_COMPARISON_KIND.DEEP);
    } else ex = WMethod.checkM(what, with);
    // org.junit.Assert.assertTrue(WMethod.sameStateSet(what,with));

    if (ex != null && failureCode == null) failureCode = ex;
  }
  /** Tests that updating a maximal automata can chop off parts of a tree. */
  @Test
  public void testPTAconstruction_max5() {
    Configuration config = mainConfiguration;
    Set<List<Label>> minusStrings = buildSet(new String[][] {new String[] {}}, config, converter);

    LearnerGraph graph =
        buildLearnerGraph(
            "A-a->B-b->C-c->A\nA-b->C-d->C", "initial_max", mainConfiguration.copy(), converter);
    graph.findVertex(VertexID.parseID("A")).setDepth(0);
    graph.config.setLearnerIdMode(Configuration.IDMode.POSITIVE_NEGATIVE);
    graph.paths.augmentPTA(minusStrings, false, true);

    final LearnerGraph expected = new LearnerGraph(mainConfiguration.copy());
    expected.getVertex(new LinkedList<Label>()).setAccept(false);
    DifferentFSMException result = WMethod.checkM(expected, graph);
    Assert.assertNull(result);
    checkDepthLabelling(graph);
  }