Add configuration to send build scans to https://ge.apache.org (#810)

* Add configuration to send build scans to https://ge.apache.org

* Add `.mvn` directories to IT tests projects that lack one

Some of the integration tests to do not have `.mvn` directories and
search up the project structure until they find the `.mvn` directory
of the root project.

This change adds `.mvn` directories with empty `maven.config` files so
that the sample projects in VCS will be as close as possible to those
executed during integration testing
This commit is contained in:
Clay Johnson
2023-06-11 13:30:10 -05:00
committed by GitHub
parent 7d9a39be1a
commit 0e07a384c4
7 changed files with 51 additions and 1 deletions

3
.gitignore vendored
View File

@@ -29,3 +29,6 @@ nb-configuration.xml
# formatter-maven-plugin
.cache/
# https://ge.apache.org
.mvn/.gradle-enterprise

14
.mvn/extensions.xml Normal file
View File

@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<extensions>
<extension>
<groupId>com.gradle</groupId>
<artifactId>gradle-enterprise-maven-extension</artifactId>
<version>1.17.3</version>
</extension>
<extension>
<groupId>com.gradle</groupId>
<artifactId>common-custom-user-data-maven-extension</artifactId>
<version>1.12</version>
</extension>
</extensions>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<gradleEnterprise
xmlns="https://www.gradle.com/gradle-enterprise-maven" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.gradle.com/gradle-enterprise-maven https://www.gradle.com/schema/gradle-enterprise-maven.xsd">
<server>
<url>https://ge.apache.org</url>
</server>
<buildScan>
<capture>
<goalInputFiles>true</goalInputFiles>
</capture>
<obfuscation>
<ipAddresses>0.0.0.0</ipAddresses>
</obfuscation>
<publish>ALWAYS</publish>
<publishIfAuthenticated>true</publishIfAuthenticated>
<backgroundBuildScanUpload>#{isFalse(env['GITHUB_ACTIONS'])}</backgroundBuildScanUpload>
</buildScan>
<buildCache>
<local>
<enabled>#{isFalse(env['GITHUB_ACTIONS'])}</enabled>
</local>
<remote>
<enabled>false</enabled>
</remote>
</buildCache>
</gradleEnterprise>

View File

@@ -204,6 +204,11 @@ public class MvndTestExtension implements BeforeAllCallback, BeforeEachCallback,
}
});
}
final Path dotMvn = testExecutionDir.resolve(".mvn");
if (!Files.exists(dotMvn)) {
Files.createDirectories(dotMvn);
}
}
final Path multiModuleProjectDirectory =
Paths.get(DaemonParameters.findDefaultMultimoduleProjectDirectory(testExecutionDir));