<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/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>io.serverlessworkflow</groupId>
        <artifactId>serverlessworkflow-parent</artifactId>
        <version>5.2.0.Final</version>
    </parent>

    <artifactId>serverlessworkflow-validation</artifactId>
    <name>Serverless Workflow :: Validation</name>
    <packaging>jar</packaging>
    <description>Java SDK for Serverless Workflow Specification</description>

    <dependencies>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>jcl-over-slf4j</artifactId>
        </dependency>

        <dependency>
            <groupId>io.serverlessworkflow</groupId>
            <artifactId>serverlessworkflow-api</artifactId>
            <version>${project.version}</version>
        </dependency>

        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
        </dependency>
        <dependency>
          <groupId>com.networknt</groupId>
          <artifactId>json-schema-validator</artifactId>
        </dependency>
        <!-- test -->
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-api</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-engine</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-params</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.assertj</groupId>
            <artifactId>assertj-core</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.hamcrest</groupId>
            <artifactId>hamcrest-library</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.skyscreamer</groupId>
            <artifactId>jsonassert</artifactId>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <configuration>
                    <checkstyleRules>
                        <module name="Checker">
                            <module name="RegexpHeader">
                                <property name="header" value="${checkstyle.header.template}" />
                                <property name="fileExtensions" value="${checkstyle.header.extensions}" />
                            </module>
                            <module name="TreeWalker">
                                <module name="RegexpSinglelineJava">
                                    <property name="format" value="@author" />
                                    <property name="message" value="No @author tag allowed" />
                                </module>
                            </module>
                        </module>
                    </checkstyleRules>
                    <outputFile>${project.build.directory}/checkstyle.log</outputFile>
                    <includeTestSourceDirectory>true</includeTestSourceDirectory>
                    <includeResources>true</includeResources>
                    <includeTestResources>true</includeTestResources>
                    <consoleOutput>false</consoleOutput>
                    <failsOnError>false</failsOnError>
                    <logViolationsToConsole>${checkstyle.logViolationsToConsole}</logViolationsToConsole>
                    <failOnViolation>${checkstyle.failOnViolation}</failOnViolation>
                    <sourceDirectories>
                        <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
                        <sourceDirectory>${project.build.testSourceDirectory}</sourceDirectory>
                    </sourceDirectories>
                </configuration>
                <executions>
                    <execution>
                        <phase>compile</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>com.spotify.fmt</groupId>
                <artifactId>fmt-maven-plugin</artifactId>
                <configuration>
                    <sourceDirectory>src/main/java</sourceDirectory>
                    <testSourceDirectory>src/test/java</testSourceDirectory>
                    <verbose>false</verbose>
                    <filesNamePattern>.*\.java</filesNamePattern>
                    <skip>false</skip>
                    <skipSortingImports>false</skipSortingImports>
                    <style>google</style>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>format</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
</project>
