@Test void testLongNameIsShortened() { String longObjectName = "veryVeryVeryLongNameThatIsLongerThan100CharactersIsExpectedToBeShortenedByLongObjectNamesResolverSuchThatFileNamesDoNotBecomeTooLong"; String resolvedFileName = resolver.resolveObjectFileName(longObjectName); assertEquals( "veryVeryVeryLongNameThatIsLongerThan100CharactersIsExpectedToBeShortenedByLongObjectNamesResolverSuc-0", resolvedFileName, "Expected shortened name with suffix of collision index (0 for no collision yet)"); }
public synchronized String resolveObjectFileName(final String fullLengthName) { if (fullLengthName.length() > 100) { return resolveLongName(fullLengthName); } else { return fullLengthName; } }
LongObjectNamesResolver { public synchronized String resolveObjectFileName(final String fullLengthName) { if (fullLengthName.length() > 100) { return resolveLongName(fullLengthName); } else { return fullLengthName; } } }
LongObjectNamesResolver { public synchronized String resolveObjectFileName(final String fullLengthName) { if (fullLengthName.length() > 100) { return resolveLongName(fullLengthName); } else { return fullLengthName; } }  }
LongObjectNamesResolver { public synchronized String resolveObjectFileName(final String fullLengthName) { if (fullLengthName.length() > 100) { return resolveLongName(fullLengthName); } else { return fullLengthName; } }  synchronized String resolveObjectFileName(final String fullLengthName); }
LongObjectNamesResolver { public synchronized String resolveObjectFileName(final String fullLengthName) { if (fullLengthName.length() > 100) { return resolveLongName(fullLengthName); } else { return fullLengthName; } }  synchronized String resolveObjectFileName(final String fullLengthName);  }