Skip to content

Apply Surefire JVM Isolation to Maven Test execution #604

Open
@jeremiahjstacey

Description

@jeremiahjstacey

Discussed in the scope of release 2.2.3.0, we're looking to update the project to remove forks from the surefire test execution environment. Doing this should remove some scale of cross-contamination of static project state across the tests, and further ensure that tests may run both as independent units as well as through the overall project execution.
Expectations at the end of this effort:

  1. Surefire configuration is updated to remove forking
  2. When run as a collective unit, all tests are successful through a full maven test cycle.
  3. When run as an independent unit, each test is successful through the maven test phase.

IDE behavior is preferred, and should be tested for issues. Minimally, the common maven behavior must be provided.

To update the Surefire configuration:

<build>
    <pluginManagement>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>${version.surefire}</version>
	            <configuration>
			        <forkCount>0</forkCount>
			        <reuseForks>false</reuseForks>
		        </configuration>
            </plugin>
    </pluginManagement>
</build>

Applying this setting current causes a number of test errors. Addressing the errors is expected be the majority of the work related to this task.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions