@Test
public void testMakeFilename() {

  final Object[][] testParameters = new Object[][] {{"HelloWorld", "", "HelloWorld"},
      {"HelloWorld", " ", "HelloWorld"}, {"HelloWorld", "\n", "HelloWorld"}, {"", "png", ".png"},
      {" ", "jpg", ".jpg"}, {"\n", "gif", ".gif"}, {"HelloWorld", "cgm", "HelloWorld.cgm"},
      {"Hello.World", "svg", "Hello.World.svg"}};
  assertNull(FilenameUtils.makeFilename(null, "png"));
  assertNull(FilenameUtils.makeFilename("HelloWorld", null));
  for (final Object[] testParameter : testParameters) {
    String expected = (String) testParameter[2];
    String name = (String) testParameter[0];
    String ext = (String) testParameter[1];
    assertEquals(expected, FilenameUtils.makeFilename(name, ext));
  }
}