@Test
public void testWrite() throws IOException, ResourceFilterException {

    File tempFile = File.createTempFile(this.getClass().getSimpleName(), ".pot");
    tempFile.deleteOnExit();
    try (OutputStream os = new FileOutputStream(tempFile)) {
        res.write(os, WRITE_BUNDLE, null);
        os.flush();
        // pot files contain a header, this has info which may change,
        // therefore, ignore it by setting n=19 in compareFiles()
        assertTrue(ResourceTestUtil.compareFiles(EXPECTED_WRITE_FILE, tempFile, 19));
    }
}