public void testVariableNameOptimization() {
    System.out.println("\n*** testVariableNameOptimization ***");
    boolean isOpenCyc =  false;
    try {
      isOpenCyc = getCyc().isOpenCyc();
      CycFormulaSentence sentence = getCyc().makeCycSentence("(#$likesAsFriend ?X ?Y)");
      Map<CycVariable, String> varMap = sentence.getOptimizedVarNames(getCyc());
      assertEquals(varMap.size(), 2);
    } catch (Exception e) {
      if (!isOpenCyc) {
        // this may or may not work under OpenCYC
        failWithException(e);
      }
    }
    System.out.println("*** testVariableNameOptimization OK ***");
  }