Skip to content

Commit 0f9870b

Browse files
committed
Stop referring to JUnit 5 in documentation
Closes gh-34970
1 parent 1f1c24c commit 0f9870b

File tree

13 files changed

+30
-30
lines changed

13 files changed

+30
-30
lines changed

framework-docs/modules/ROOT/pages/languages/kotlin/spring-projects-in.adoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ progresses.
324324
== Testing
325325

326326
This section addresses testing with the combination of Kotlin and Spring Framework.
327-
The recommended testing framework is https://junit.org/junit5/[JUnit 5] along with
327+
The recommended testing framework is https://junit.org/junit5/[JUnit] along with
328328
https://mockk.io/[Mockk] for mocking.
329329

330330
NOTE: If you are using Spring Boot, see
@@ -335,7 +335,7 @@ NOTE: If you are using Spring Boot, see
335335
=== Constructor injection
336336

337337
As described in the xref:testing/testcontext-framework/support-classes.adoc#testcontext-junit-jupiter-di[dedicated section],
338-
JUnit Jupiter (JUnit 5) allows constructor injection of beans which is pretty useful with Kotlin
338+
JUnit Jupiter allows constructor injection of beans which is pretty useful with Kotlin
339339
in order to use `val` instead of `lateinit var`. You can use
340340
{spring-framework-api}/test/context/TestConstructor.html[`@TestConstructor(autowireMode = AutowireMode.ALL)`]
341341
to enable autowiring for all parameters.
@@ -360,7 +360,7 @@ file with a `spring.test.constructor.autowire.mode = all` property.
360360
=== `PER_CLASS` Lifecycle
361361

362362
Kotlin lets you specify meaningful test function names between backticks (```).
363-
With JUnit Jupiter (JUnit 5), Kotlin test classes can use the `@TestInstance(TestInstance.Lifecycle.PER_CLASS)`
363+
With JUnit Jupiter, Kotlin test classes can use the `@TestInstance(TestInstance.Lifecycle.PER_CLASS)`
364364
annotation to enable single instantiation of test classes, which allows the use of `@BeforeAll`
365365
and `@AfterAll` annotations on non-static methods, which is a good fit for Kotlin.
366366

@@ -404,8 +404,8 @@ class IntegrationTests {
404404
[[specification-like-tests]]
405405
=== Specification-like Tests
406406

407-
You can create specification-like tests with JUnit 5 and Kotlin.
408-
The following example shows how to do so:
407+
You can create specification-like tests with Kotlin and JUnit Jupiter's `@Nested` test
408+
class support. The following example shows how to do so:
409409

410410
[source,kotlin,indent=0]
411411
----

framework-docs/modules/ROOT/pages/testing/annotations/integration-junit-jupiter.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
= Spring JUnit Jupiter Testing Annotations
33

44
The following annotations are supported when used in conjunction with the
5-
xref:testing/testcontext-framework/support-classes.adoc#testcontext-junit-jupiter-extension[`SpringExtension`] and JUnit Jupiter
6-
(that is, the programming model in JUnit 5):
5+
xref:testing/testcontext-framework/support-classes.adoc#testcontext-junit-jupiter-extension[`SpringExtension`]
6+
and JUnit Jupiter (that is, the programming model in JUnit):
77

88
* xref:testing/annotations/integration-junit-jupiter.adoc#integration-testing-annotations-junit-jupiter-springjunitconfig[`@SpringJUnitConfig`]
99
* xref:testing/annotations/integration-junit-jupiter.adoc#integration-testing-annotations-junit-jupiter-springjunitwebconfig[`@SpringJUnitWebConfig`]

framework-docs/modules/ROOT/pages/testing/annotations/integration-meta.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,8 +140,8 @@ Kotlin::
140140
======
141141

142142
If we write tests that use JUnit Jupiter, we can reduce code duplication even further,
143-
since annotations in JUnit 5 can also be used as meta-annotations. Consider the following
144-
example:
143+
since annotations in JUnit Jupiter can also be used as meta-annotations. Consider the
144+
following example:
145145

146146
[tabs]
147147
======

framework-docs/modules/ROOT/pages/testing/testcontext-framework.adoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ deal of importance on convention over configuration, with reasonable defaults th
99
can override through annotation-based configuration.
1010

1111
In addition to generic testing infrastructure, the TestContext framework provides
12-
explicit support for JUnit 4, JUnit Jupiter (AKA JUnit 5), and TestNG. For JUnit 4 and
13-
TestNG, Spring provides `abstract` support classes. Furthermore, Spring provides a custom
14-
JUnit `Runner` and custom JUnit `Rules` for JUnit 4 and a custom `Extension` for JUnit
15-
Jupiter that let you write so-called POJO test classes. POJO test classes are not
16-
required to extend a particular class hierarchy, such as the `abstract` support classes.
12+
explicit support for JUnit Jupiter, JUnit 4, and TestNG. For JUnit 4 and TestNG, Spring
13+
provides `abstract` support classes. Furthermore, Spring provides a custom JUnit `Runner`
14+
and custom JUnit `Rules` for JUnit 4 and a custom `Extension` for JUnit Jupiter that let
15+
you write so-called POJO test classes. POJO test classes are not required to extend a
16+
particular class hierarchy, such as the `abstract` support classes.
1717

1818
The following section provides an overview of the internals of the TestContext framework.
1919
If you are interested only in using the framework and are not interested in extending it

framework-docs/modules/ROOT/pages/testing/testcontext-framework/support-classes.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ in JUnit and TestNG.
99
== SpringExtension for JUnit Jupiter
1010

1111
The Spring TestContext Framework offers full integration with the JUnit Jupiter testing
12-
framework, introduced in JUnit 5. By annotating test classes with
12+
framework, originally introduced in JUnit 5. By annotating test classes with
1313
`@ExtendWith(SpringExtension.class)`, you can implement standard JUnit Jupiter-based unit
1414
and integration tests and simultaneously reap the benefits of the TestContext framework,
1515
such as support for loading application contexts, dependency injection of test instances,
@@ -72,8 +72,8 @@ Kotlin::
7272
----
7373
======
7474

75-
Since you can also use annotations in JUnit 5 as meta-annotations, Spring provides the
76-
`@SpringJUnitConfig` and `@SpringJUnitWebConfig` composed annotations to simplify the
75+
Since you can also use annotations in JUnit Jupiter as meta-annotations, Spring provides
76+
the `@SpringJUnitConfig` and `@SpringJUnitWebConfig` composed annotations to simplify the
7777
configuration of the test `ApplicationContext` and JUnit Jupiter.
7878

7979
The following example uses `@SpringJUnitConfig` to reduce the amount of configuration

spring-test/src/main/java/org/springframework/test/context/junit/jupiter/DisabledIf.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2022 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -55,7 +55,7 @@
5555
* {@link org.junit.jupiter.api.condition.DisabledOnOs @DisabledOnOs(MAC)} support
5656
* in JUnit Jupiter.
5757
*
58-
* <p>Since JUnit 5.7, JUnit Jupiter also has a condition annotation named
58+
* <p>JUnit Jupiter also has a condition annotation named
5959
* {@link org.junit.jupiter.api.condition.DisabledIf @DisabledIf}. Thus, if you
6060
* wish to use Spring's {@code @DisabledIf} support make sure you import the
6161
* annotation type from the correct package.

spring-test/src/main/java/org/springframework/test/context/junit/jupiter/DisabledIfCondition.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2017 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -22,7 +22,7 @@
2222
/**
2323
* {@code DisabledIfCondition} is an {@link org.junit.jupiter.api.extension.ExecutionCondition}
2424
* that supports the {@link DisabledIf @DisabledIf} annotation when using the <em>Spring
25-
* TestContext Framework</em> in conjunction with JUnit 5's <em>Jupiter</em> programming model.
25+
* TestContext Framework</em> in conjunction with the JUnit Jupiter testing framework.
2626
*
2727
* <p>Any attempt to use the {@code DisabledIfCondition} without the presence of
2828
* {@link DisabledIf @DisabledIf} will result in an <em>enabled</em>

spring-test/src/main/java/org/springframework/test/context/junit/jupiter/EnabledIf.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2022 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -55,7 +55,7 @@
5555
* {@link org.junit.jupiter.api.condition.EnabledOnOs @EnabledOnOs(MAC)} support
5656
* in JUnit Jupiter.
5757
*
58-
* <p>Since JUnit 5.7, JUnit Jupiter also has a condition annotation named
58+
* <p>JUnit Jupiter also has a condition annotation named
5959
* {@link org.junit.jupiter.api.condition.EnabledIf @EnabledIf}. Thus, if you
6060
* wish to use Spring's {@code @EnabledIf} support make sure you import the
6161
* annotation type from the correct package.

spring-test/src/main/java/org/springframework/test/context/junit/jupiter/EnabledIfCondition.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2017 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -22,7 +22,7 @@
2222
/**
2323
* {@code EnabledIfCondition} is an {@link org.junit.jupiter.api.extension.ExecutionCondition}
2424
* that supports the {@link EnabledIf @EnabledIf} annotation when using the <em>Spring
25-
* TestContext Framework</em> in conjunction with JUnit 5's <em>Jupiter</em> programming model.
25+
* TestContext Framework</em> in conjunction with the JUnit Jupiter testing framework.
2626
*
2727
* <p>Any attempt to use the {@code EnabledIfCondition} without the presence of
2828
* {@link EnabledIf @EnabledIf} will result in an <em>enabled</em>

spring-test/src/main/java/org/springframework/test/context/junit/jupiter/SpringExtension.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565

6666
/**
6767
* {@code SpringExtension} integrates the <em>Spring TestContext Framework</em>
68-
* into JUnit 5's <em>Jupiter</em> programming model.
68+
* into the JUnit Jupiter testing framework.
6969
*
7070
* <p>To use this extension, simply annotate a JUnit Jupiter based test class with
7171
* {@code @ExtendWith(SpringExtension.class)}, {@code @SpringJUnitConfig}, or

spring-test/src/main/java/org/springframework/test/context/junit/jupiter/package-info.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* Core support for integrating the <em>Spring TestContext Framework</em>
3-
* with the JUnit Jupiter extension model in JUnit 5.
3+
* with the JUnit Jupiter testing framework.
44
*/
55
@NullMarked
66
package org.springframework.test.context.junit.jupiter;

spring-test/src/main/java/org/springframework/test/context/junit/jupiter/web/package-info.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* Web support for integrating the <em>Spring TestContext Framework</em>
3-
* with the JUnit Jupiter extension model in JUnit 5.
3+
* with the JUnit Jupiter extension model.
44
*/
55
@NullMarked
66
package org.springframework.test.context.junit.jupiter.web;

spring-test/src/test/java/org/springframework/test/context/junit/SpringJUnitJupiterTestSuite.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2021 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -24,7 +24,7 @@
2424

2525
/**
2626
* JUnit Platform based test suite for tests that involve the Spring TestContext
27-
* Framework and JUnit Jupiter (i.e., JUnit 5's programming model).
27+
* Framework and JUnit Jupiter.
2828
*
2929
* <p><strong>This suite is only intended to be used manually within an IDE.</strong>
3030
*

0 commit comments

Comments
 (0)