class MavenProjectProperties implements ProjectProperties {

  @VisibleForTesting
  Path getWarArtifact() {
    Build build = project.getBuild();
    String warName = build.getFinalName();

    Plugin warPlugin = project.getPlugin("org.apache.maven.plugins:maven-war-plugin");
    if (warPlugin != null) {
      for (PluginExecution execution : warPlugin.getExecutions()) {
        if ("default-war".equals(execution.getId())) {
          Xpp3Dom configuration = (Xpp3Dom) execution.getConfiguration();
          warName = getChildValue(configuration, "warName").orElse(warName);
        }
      }
    }

    return Paths.get(build.getDirectory(), warName + ".war");
  }

  @VisibleForTesting  MavenProjectProperties(
      PluginDescriptor jibPluginDescriptor,
      MavenProject project,
      MavenSession session,
      Log log,
      TempDirectoryProvider tempDirectoryProvider,
      Supplier<List<JibMavenPluginExtension<?>>> extensionLoader);

}