/**
   * Testcase from Stefan.
   *
   * <p>- Is form a nature paper and a holo and apo form of a protein... - Testcase for an alignment
   * - AND - testcase if all aminos and hetagtoms get indexed...
   */
  public void testAllAgainstAll() {

    int ngramSize = 17;

    String pathToTargetDirOrFile = "src/test/resources/nature_paper_apo_holo/";
    String pathToQueryDirOrFile = pathToTargetDirOrFile;

    String outputFilePath = tempDir + File.separator + this.getClass().getSimpleName() + "/";

    boolean dealOnlyWithFirstModel = true;

    IFileToStringTranslator iFileToStringTranslator =
        new PDBProteinTranslator(
            iResidueToStringTransformer,
            dealOnlyWithFirstModel,
            scoringFunction,
            ngramTo3DTranslator);

    double thresholdOfRefinementScoreUnderWichResultIsOmitted = 0.3;

    // set up and clean:
    DeleteDirRecursively.deleteDir(new File(tempDir));

    ProteinMatchRunner.executeSearch(
        ngramSize,
        iFileToStringTranslator,
        iResidueToStringTransformer,
        pathToTargetDirOrFile,
        pathToQueryDirOrFile,
        outputFilePath,
        dealOnlyWithFirstModel,
        thresholdOfRefinementScoreUnderWichResultIsOmitted,
        1);

    // check if there are two result dirs with 2 perfect matches each...

    // check if there are two result dirs with 2 perfect matches each...
    String[] dirNames = new File(outputFilePath).list();

    // 0. check if there are 8 result dirs in general:
    if (dirNames.length != 2) {
      fail();
    }

    // 1. for each resultdir check if there are enough result files:
    for (String dirName : dirNames) {

      String resultDirFileName = outputFilePath + File.separator + dirName;
      // System.out.println(resultDirFileName + " " + new File(resultDirFileName).list().length);

      if (new File(resultDirFileName).list().length != 3) {

        fail();
      }
    }

    // tear down and clean:
    // DeleteDirRecursively.deleteDir(new File(tempDir));

  }
  public void testLength10() {

    String tempDir = "src/test/tmp";

    int ngramSize = 10;

    // apoform
    String pathToTargetDirOrFile =
        "src/test/resources/bindingsitedetection/dominic_testfall/proteine/1ABB_C.ent";

    // binding site of holo
    String pathToQueryDirOrFile =
        "src/test/resources/bindingsitedetection/dominic_testfall/binding_sites/1H5U_A_999.ent";

    String outputFilePath = "src/test/tmp/" + this.getClass().getSimpleName() + "/";

    boolean dealOnlyWithFirstModel = true;

    IFileToStringTranslator iFileToStringTranslator =
        new PDBProteinTranslator(
            iResidueToStringTransformer,
            dealOnlyWithFirstModel,
            scoringFunction,
            ngramTo3DTranslator);

    double thresholdOfRefinementScoreUnderWichResultIsOmitted = 0.6;

    // set up and clean:
    DeleteDirRecursively.deleteDir(new File(tempDir));

    ProteinMatchRunner.executeSearch(
        ngramSize,
        iFileToStringTranslator,
        iResidueToStringTransformer,
        pathToTargetDirOrFile,
        pathToQueryDirOrFile,
        outputFilePath,
        dealOnlyWithFirstModel,
        thresholdOfRefinementScoreUnderWichResultIsOmitted,
        1);

    // check if there are two result dirs with 2 perfect matches each...

    File chainADir = new File(outputFilePath + File.separator + "1H5U_A_999.ent-model-0-chain-A");

    String[] allFiles = chainADir.list();

    if (allFiles.length != 2) {
      fail();
    }

    // tear down and clean:
    // DeleteDirRecursively.deleteDir(new File(tempDir));

  }