public String objectTypePairsToString() {
    StringBuilder result = new StringBuilder();
    for ( Map.Entry entry : objectTypePairs.entrySet() ) {
      if ( entry.getKey() != null ) {
        result.append( Const.CR );
        result.append( "\"" );
        result.append( entry.getKey() );
        result.append( "\"" );
        result.append( " [" );
        result.append( entry.getValue() );
        result.append( "] " );
      }
    }
    return result.toString();
  }
@Test
  public void testObjectTypePairsToString() throws Exception {
    Exception cause = new NullPointerException();

    Map<String, RepositoryObjectType> notFoundedReferences = new LinkedHashMap<String, RepositoryObjectType>();
    String pathToTransStub = "/path/Trans.ktr";
    String pathToJobStub = "/path/Job.ktr";
    notFoundedReferences.put( pathToTransStub, RepositoryObjectType.TRANSFORMATION );
    notFoundedReferences.put( pathToJobStub, RepositoryObjectType.JOB );

    String expectedOutput =
        System.lineSeparator() + "\"/path/Trans.ktr\" [transformation] " + System.lineSeparator()
            + "\"/path/Job.ktr\" [job] ";
    try {
      throw new LookupReferencesException( cause, notFoundedReferences );
    } catch ( LookupReferencesException testedException ) {
      String actual = testedException.objectTypePairsToString();
      assertEquals( expectedOutput, actual );
      //check that cause exception was set
      assertNotNull( testedException.getCause() );
    }
  }