### Question:
FileBasedComponent implements DeclaringComponent { public static FileBasedComponent fileSource(File file, int lineNumber, boolean yaml, String configType, String environment) { return new FileBasedComponent(file, lineNumber, yaml, configType, environment); }  static FileBasedComponent fileSource(File file, int lineNumber, boolean yaml,
                                                String configType, String environment); @Override String getComponent(); @Override String toString();  }### Answer:
@Test void factoryMethod() { assertEquals(source, fileSource(file, 0, true, "app", "dev")); }