<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <parent>
    <groupId>com.kinde</groupId>
    <artifactId>kinde-parent-pom</artifactId>
    <version>2.0.0</version>
  </parent>

  <groupId>com.kinde</groupId>
  <artifactId>kinde-core</artifactId>
  <packaging>jar</packaging>
  <version>2.0.0</version>
  <name>kinde-core</name>
  <url>http://maven.apache.org</url>

  <dependencies>
    <!-- https://mvnrepository.com/artifact/com.nimbusds/oauth2-oidc-sdk -->
    <dependency>
      <groupId>com.nimbusds</groupId>
      <artifactId>oauth2-oidc-sdk</artifactId>
      <version>11.14</version>
    </dependency>
    <dependency>
      <groupId>com.nimbusds</groupId>
      <artifactId>nimbus-jose-jwt</artifactId>
      <version>9.40</version>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.8.1</version>
      <scope>test</scope>
    </dependency>
    <!-- JUnit 5 API and Engine -->
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-api</artifactId>
      <version>5.10.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-engine</artifactId>
      <version>5.10.0</version>
      <scope>test</scope>
    </dependency>

    <!-- Optional: For parameterized tests -->
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-params</artifactId>
      <version>5.10.0</version>
      <scope>test</scope>
    </dependency>

    <!-- Mockito (if you are using it for mocking) -->
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-core</artifactId>
      <version>5.4.0</version>
      <scope>test</scope>
    </dependency>


    <dependency>
      <groupId>com.google.inject</groupId>
      <artifactId>guice</artifactId>
      <!-- {version} can be 6.0.0, 7.0.0, etc. -->
      <version>7.0.0</version>
    </dependency>
    <!-- https://mvnrepository.com/artifact/org.projectlombok/lombok -->
    <dependency>
      <groupId>org.projectlombok</groupId>
      <artifactId>lombok</artifactId>
      <version>1.18.34</version>
      <scope>provided</scope>
    </dependency>
    <!-- https://mvnrepository.com/artifact/org.slf4j/slf4j-api -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>2.0.15</version>
    </dependency>
    <dependency>
      <groupId>io.github.cdimascio</groupId>
      <artifactId>dotenv-java</artifactId>
      <version>3.0.0</version>
    </dependency>
    <dependency>
      <groupId>com.github.tomakehurst</groupId>
      <artifactId>wiremock-jre8</artifactId>
      <version>2.33.2</version>
      <scope>test</scope>
    </dependency>
  </dependencies>
  <build>
    <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>3.2.5</version>
          <configuration>
            <parallel>none</parallel>
          </configuration>
        </plugin>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <version>0.8.10</version> <!-- Replace with the latest version -->
        <executions>
          <execution>
            <goals>
              <goal>prepare-agent</goal>
            </goals>
          </execution>
          <execution>
            <id>report</id>
            <phase>prepare-package</phase>
            <goals>
              <goal>report</goal>
            </goals>
          </execution>
          <execution>
            <id>post-unit-test</id>
            <phase>test</phase>
            <goals>
              <goal>report</goal>
            </goals>
            <configuration>
              <outputDirectory>${project.build.directory}/jacoco</outputDirectory>
              <dataFile>${project.build.directory}/jacoco/jacoco.exec</dataFile>
              <reportFormats>
                <format>HTML</format>
                <format>XML</format>
              </reportFormats>
              <append>true</append>
              <skip>false</skip>
              <includes>
                <include>com/kinde/**</include>
              </includes>
              <excludes>
                <exclude>com/google/inject/**/*.class</exclude>
                <exclude>javax/inject/**/*.class</exclude>
                <exclude>org/springframework/**/*.class</exclude>
                <exclude>**/generated/**</exclude>
                <exclude>**/thirdparty/**</exclude>
                <!-- Add more excludes if necessary -->
              </excludes>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
          <groupId>org.sonatype.plugins</groupId>
          <artifactId>nexus-staging-maven-plugin</artifactId>
      </plugin>
    </plugins>
  </build>
</project>
