### Question:
ReadFile { public static StringBuilder getFileContentsFromResourceAsStringBuilder( String resourceLocation, ClassLoader classLoader) throws IOException { InputStream inputStream = classLoader.getResourceAsStream(resourceLocation); if (inputStream == null) { throw new FileNotFoundException("Could not find resource file at path '" + resourceLocation + "'"); } return getFileContents(inputStream); }  static String getFileContentsFromResource(String resourceLocation); static String getFileContentsFromResource(String resourceLocation, ClassLoader classLoader); static StringBuilder getFileContentsFromResourceAsStringBuilder(
            String resourceLocation,
            ClassLoader classLoader); static String getFileContents(File file); static StringBuilder getFileContents(InputStream inputStream); static StringBuilder getFileContents(Reader reader);  }### Answer:
@Test public void getFileContentsFromResourceAsStringBuilderTest() throws IOException { final StringBuilder sb = ReadFile.getFileContentsFromResourceAsStringBuilder( TESTFILE, Thread.currentThread().getContextClassLoader()); assertFalse(sb.length() == 0); }