Skip to content

Commit a170306

Browse files
authored
Merge branch 'main' into experiments/junit-onramp
2 parents 61c678d + 8e3a042 commit a170306

File tree

3 files changed

+12
-12
lines changed

3 files changed

+12
-12
lines changed

junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/TestInstantiationAwareExtension.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
* Interface for {@link Extension Extensions} that are aware and can influence
2222
* the instantiation of test instances.
2323
*
24-
* <p>This interface is not indented to be implemented directly. Instead, extend
24+
* <p>This interface is not intended to be implemented directly. Instead, extend
2525
* one of its sub-interfaces.
2626
*
2727
* @since 5.12

junit-jupiter-params/src/main/java/org/junit/jupiter/params/ParameterizedInvocationContextProvider.java

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -37,19 +37,18 @@ protected Stream<T> provideInvocationContexts(ExtensionContext extensionContext,
3737
declarationContext);
3838
AtomicLong invocationCount = new AtomicLong(0);
3939

40-
// @formatter:off
41-
return argumentsSources
42-
.stream()
43-
.map(ArgumentsSource::value)
44-
.map(clazz -> ParameterizedTestSpiInstantiator.instantiate(ArgumentsProvider.class, clazz, extensionContext))
45-
.map(provider -> AnnotationConsumerInitializer.initialize(declarationContext.getAnnotatedElement(), provider))
46-
.flatMap(provider -> arguments(provider, parameters, extensionContext))
40+
return argumentsSources.stream() //
41+
.map(ArgumentsSource::value) //
42+
.map(clazz -> ParameterizedTestSpiInstantiator.instantiate(ArgumentsProvider.class, clazz,
43+
extensionContext)) //
44+
.map(provider -> AnnotationConsumerInitializer.initialize(declarationContext.getAnnotatedElement(),
45+
provider)) //
46+
.flatMap(provider -> arguments(provider, parameters, extensionContext)) //
4747
.map(arguments -> {
4848
invocationCount.incrementAndGet();
4949
return declarationContext.createInvocationContext(formatter, arguments, invocationCount.intValue());
50-
})
51-
.onClose(() -> validateInvokedAtLeastOnce(invocationCount.get(),declarationContext ));
52-
// @formatter:on
50+
}) //
51+
.onClose(() -> validateInvokedAtLeastOnce(invocationCount.get(), declarationContext));
5352
}
5453

5554
private static <T> void validateInvokedAtLeastOnce(long invocationCount,

platform-tests/src/test/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListenerTests.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ void includesGitInfoWhenEnabled(String originUrl, @TempDir Path tempDirectory) t
191191

192192
execGit(tempDirectory, "config", "user.name", "Alice");
193193
execGit(tempDirectory, "config", "user.email", "[email protected]");
194-
execGit(tempDirectory, "commit", "-m", "Initial commit");
194+
execGit(tempDirectory, "commit", "--no-gpg-sign", "-m", "Initial commit");
195195

196196
var engine = new DemoHierarchicalTestEngine("dummy");
197197

@@ -280,6 +280,7 @@ private static ProcessResult tryExecGit(Path workingDir, String... arguments) th
280280
System.out.println("$ git " + String.join(" ", arguments));
281281
return new ProcessStarter() //
282282
.executable(Path.of("git")) //
283+
.putEnvironment("GIT_CONFIG_GLOBAL", "/dev/null") // https://git-scm.com/docs/git#Documentation/git.txt-GITCONFIGGLOBAL
283284
.workingDir(workingDir) //
284285
.addArguments(arguments) //
285286
.startAndWait();

0 commit comments

Comments
 (0)