Sébastien Deleuze
cfd0aee4db
Polish and add MockMvcExtensionsTests.queryParameter
...
Closes gh-32371
2024-03-05 10:59:12 +01:00
corby kim
132fbe228f
Add query parameters to MockMvc Kotlin DSL
...
See gh-32371
2024-03-05 10:56:41 +01:00
Juergen Hoeller
dc6c96de0a
Merge branch '6.1.x'
...
# Conflicts:
# spring-context-support/src/main/java/org/springframework/cache/jcache/interceptor/AbstractFallbackJCacheOperationSource.java
# spring-context/src/main/java/org/springframework/cache/interceptor/AbstractFallbackCacheOperationSource.java
# spring-tx/src/main/java/org/springframework/transaction/interceptor/AbstractFallbackTransactionAttributeSource.java
2024-03-04 22:50:22 +01:00
Juergen Hoeller
e9110c0729
Polishing
2024-03-04 22:48:52 +01:00
Sam Brannen
c76d681dc4
Merge branch '6.1.x'
2024-03-01 14:41:49 +01:00
Sam Brannen
de828e9764
Improve documentation for @Sql execution phases regarding lifecycle
...
Closes gh-32343
2024-03-01 14:37:31 +01:00
Juergen Hoeller
f22a1eece4
Polishing
2024-02-28 19:14:37 +01:00
Juergen Hoeller
cfb29db278
Initial support for Servlet 6.1
...
Closes gh-31159
2024-02-28 18:54:36 +01:00
Sam Brannen
122372c580
Spring cleaning: update copyright headers
2024-02-23 12:21:22 +01:00
Sam Brannen
4bd1485ce4
Spring cleaning: use method references
2024-02-23 12:20:11 +01:00
Sam Brannen
644887e094
Polish (Linked)HashSet usage
...
See gh-32291
2024-02-21 16:22:31 +01:00
Sam Brannen
b9c304b890
Polish contribution
...
See gh-32291
2024-02-21 16:19:53 +01:00
Patrick Strawderman
e1a32d4ba9
Avoid resizing of fixed-size HashSet/LinkedHashSet variants
...
Add helpers to CollectionUtils for building HashSets and LinkedHashSets
that can hold an expected number of elements without needing to
resize/rehash.
Closes gh-32291
2024-02-21 16:19:53 +01:00
Sam Brannen
ea4e7df9ca
Consistently declare ignoreUnresolvablePlaceholders as last argument
2024-02-16 15:00:32 +01:00
Sam Brannen
b6df5a677e
Polishing
2024-02-16 11:41:22 +01:00
Stéphane Nicoll
e3aa5b6b11
Use new implementation in PropertyPlaceholderHelper
...
This commit removes the previous implementation in favor of the new
PlaceholderParser. The only noticeable side effect is that the exception
is no longer an IllegalArgumentException, but rather the dedicated
PlaceholderResolutionException.
See gh-9628
2024-02-15 15:27:13 +01:00
Stéphane Nicoll
e73bbd4ad3
Configure jsonpath MappingProvider in WebTestClient
...
This commit improves jsonpath support in WebTestClient by detecting
a suitable json encoder/decoder that can be applied to assert more
complex data structure.
Closes gh-31653
2024-02-15 14:41:30 +01:00
Stéphane Nicoll
9f8038963f
Allow JsonPathExpectationsHelper to use a custom configuration
...
This commit improves JsonPathExpectationsHelper to allow a custom json
path configuration to be defined. The primary objective of a custom
configuration is to specify a custom mapper that can deserialize complex
object structure.
As part of this commit, it is now possible to invoke a Matcher against
a type that holds generic information, using a regular
ParameterizedTypeReference.
Given that the existing constructor takes a vararg of Object, this
commit also deprecates this constructor in favor of formatting the
expression String upfront.
Closes gh-31651
2024-02-15 13:57:40 +01:00
Stéphane Nicoll
4f8eca1350
Order methods that take a type as a lambda consistently
...
Closes gh-32062
2024-02-15 13:57:17 +01:00
Stéphane Nicoll
c04d4da9a3
Polish
2024-02-05 09:11:04 +01:00
Stéphane Nicoll
ea52ecc5e0
Polish
2024-02-02 18:56:41 +01:00
Juergen Hoeller
7e5efdd8dd
Reuse MapPropertySource for DynamicValuesPropertySource implementation
...
Closes gh-32110
2024-01-29 13:04:02 +01:00
Sam Brannen
3ce7c52030
Update copyright headers
2024-01-26 14:11:37 +01:00
Juergen Hoeller
d7778c0212
Polishing
2024-01-23 18:31:31 +01:00
Juergen Hoeller
531ac89e7e
Expose sendError message as default body
...
Closes gh-26720
2024-01-23 18:31:26 +01:00
Sam Brannen
5856d2e54e
Polish contribution
...
See gh-32069
2024-01-21 16:27:59 +01:00
mnhock
a8fa98e2a6
Remove unnecessary semicolons in enum declarations
...
Closes gh-32069
2024-01-21 16:25:36 +01:00
Stéphane Nicoll
1b312b6f3f
Polish
2024-01-16 18:45:59 +01:00
Stéphane Nicoll
dc5a21fbd1
Remove outdated note
...
See gh-20606
2024-01-16 16:43:28 +01:00
Stéphane Nicoll
e0c5068d0b
Fix incorrect assertions using json path
...
Closes gh-32036
2024-01-16 10:59:43 +01:00
Stéphane Nicoll
faba044735
Polish JsonPathExpectationsHelperTests
2024-01-15 17:04:11 +01:00
Stéphane Nicoll
4d885f9aad
Polish
2024-01-15 16:45:53 +01:00
Stéphane Nicoll
0c42965fc3
Polish
2024-01-15 11:17:19 +01:00
Sam Brannen
4b0443090a
Polish Javadoc for test annotations
2024-01-09 16:32:22 +01:00
Sébastien Deleuze
598c972a78
Update ContentRequestMatchers#multipartData Javadoc
...
This commit updates ContentRequestMatchers#multipartData
Javadoc to mention Tomcat fork of Commons FileUpload library
instead of the original variant.
It also adds a similar note to
ContentRequestMatchers#multipartDataContains.
Closes gh-31988
2024-01-09 14:12:09 +01:00
Stéphane Nicoll
1f2d29ee08
Polish
2024-01-08 17:12:33 +01:00
Stéphane Nicoll
2d3b02a89d
Polish
2024-01-08 11:48:08 +01:00
Sam Brannen
085af10afd
Polishing
2024-01-05 18:16:39 +01:00
Sam Brannen
580d9f81e2
Polishing
2024-01-05 17:06:32 +01:00
Sam Brannen
79b0d71514
Support the use of @Resource in test classes in AOT mode
...
Closes gh-31733
2024-01-05 16:31:18 +01:00
Juergen Hoeller
07097976ef
Polishing
2024-01-05 10:08:57 +01:00
Brian Clozel
f846d9484c
Add Javadoc to MockHttpServletResponse
...
This commit adds Javadoc to the `getContentLength` method of
`MockHttpServletResponse` to reflect that it gets its value from the
HTTP response header.
Closes gh-31833
2024-01-03 15:19:53 +01:00
Sam Brannen
6eed2b0aee
Upgrade to "TestNG Engine for the JUnit Platform" version 1.0.5
...
Thanks to a bug fix in 1.0.5, test methods in TestNG test classes can
finally be package private as was always the case with TestNG itself.
See https://github.com/junit-team/testng-engine/issues/16
2024-01-02 16:46:24 +01:00
Stéphane Nicoll
7cfff4049d
Polish "Remove unnecessary final modifier"
...
See gh-31916
2023-12-28 13:01:44 +01:00
Yanming Zhou
45080e3724
Remove unnecessary final modifier
...
final is useless for private and static methods
See gh-31916
2023-12-28 13:01:43 +01:00
Stéphane Nicoll
cd8bc2f82a
Remove useless empty inheritDoc Javadoc tag
2023-12-22 11:23:11 +01:00
Yaklede
b56fc50c27
Update copyright headers in spring-test
...
Closes gh-31853
2023-12-16 14:23:37 +01:00
Yanming Zhou
afcd03bddc
Replace assertThat(x.isEmpty()).isTrue() with assertThat(x).isEmpty()
...
Search for : assertThat\((.+).isEmpty\(\)\).isTrue\(\)
Replace with : assertThat($1).isEmpty()
Search for : assertThat\((.+).isEmpty\(\)\).isFalse\(\)
Replace with : assertThat($1).isNotEmpty()
Closes gh-31758
2023-12-06 10:04:56 +01:00
Yanming Zhou
e2852e7355
Replace assertThat(x.contains(y)).isTrue() with assertThat(x).contains(y)
...
Search for : assertThat\((.+)\.contains\((.+)\)\)\.isTrue\(\)
Replace with : assertThat($1).contains($2)
Search for : assertThat\((.+)\.contains\((.+)\)\)\.isFalse\(\)
Replace with : assertThat($1).doesNotContain($2)
Closes gh-31762
2023-12-06 09:48:49 +01:00
Yanming Zhou
59815cefce
Replace assertThat(x.get(i)). with assertThat(x).element(i).
...
Search for : assertThat\((.+)\.get\((\d+)\)\)\.
Replace with : assertThat($1).element($2).
Closes gh-31759
2023-12-06 09:43:59 +01:00
Yanming Zhou
785ad399e9
Replace assertThat(x.iterator().next()) with assertThat(x).element(0)
...
Search for : assertThat\((.+).iterator\(\).next\(\)\)
Replace with : assertThat($1).element(0)
2023-12-06 10:52:39 +08:00
Sam Brannen
c74d60b9fe
Polishing
2023-12-05 16:14:13 +01:00
Sam Brannen
db48813181
Polish contribution
...
See gh-31757
2023-12-05 16:14:13 +01:00
HyeongMokJeong
a596c0e226
Introduce overloaded MockPart constructor that accepts the Content-Type
...
Closes gh-31757
2023-12-05 15:55:33 +01:00
Sam Brannen
e870912fa2
Polish Javadoc for MockRestServiceServer
...
See gh-31741
2023-12-03 19:24:46 +01:00
Donghun Shin
99f50ebeb4
Fix Javadoc for MockRestServiceServer.bindTo(RestClient.Builder)
...
Closes gh-31741
2023-12-03 19:15:35 +01:00
Stéphane Nicoll
c92a0bd493
Prevent AotDetector to be initialized at build-time
...
This commit moves the condition used by `@DisabledInAotMode` to a
concrete implementation rather than using `@DisabledIf` as it causes
build initialization in a native image.
Closes gh-31705
2023-11-28 15:46:31 +01:00
Sam Brannen
246833329f
Register runtime hints for skipped exceptions in the TestContext framework
...
Closes gh-31479
2023-11-27 15:42:20 +01:00
Sam Brannen
97264c77dd
Consistently log exceptions from TestExecutionListeners at WARN level
...
Prior to this commit, the TestContextManager logged an exception from a
TestExecutionListener at WARN level except in prepareTestInstance()
where such an exception was logged at ERROR level (except for a skipped
exception which is logged at INFO level).
For consistency, this commit modifies TestContextManager so that it
always logs non-skipped exceptions from TestExecutionListeners at WARN
level.
Closes gh-31688
2023-11-26 12:44:13 +01:00
Sam Brannen
b17f3bc07b
Polishing
2023-11-26 12:31:15 +01:00
Sam Brannen
95e250d4bd
Log test aborted exceptions at INFO level in the TestContext framework
...
Prior to this commit, any time an aborted/skipped exception was thrown
by a TestExecutionListener, the TestContextManager unconditionally
logged the exception at WARN level -- or ERROR level for
prepareTestInstance() callbacks.
Regarding the latter, an aborted/skipped exception is certainly not an
ERROR, and in general the associated log output is very verbose
(including a stack trace) and not something the user should be warned
about it.
To improve the user experience, this commit revises TestContextManager
so that it logs such exceptions at INFO level.
Specifically, the following types of exceptions are considered
aborted/skipped exceptions.
- JUnit Jupiter: org.opentest4j.TestAbortedException
- JUnit 4 org.junit.AssumptionViolatedException
- TestNG: org.testng.SkipException
Closes gh-31479
2023-11-25 18:12:43 +01:00
Sam Brannen
dbad9fd208
Update copyright headers
2023-11-25 14:59:40 +01:00
Brian Clozel
b2757d9a21
Add Javadoc to MockHttpServletResponse#getErrorMessage
...
Closes gh-31386
2023-11-24 14:41:36 +01:00
Sam Brannen
878b33c56f
Further polish LruContextCacheTests
...
See gh-31640
2023-11-21 11:29:09 +01:00
Yanming Zhou
f46902869f
Polish LruContextCacheTests
...
Use AssertJ's extracting() feature instead of ReflectionTestUtils.getField().
Closes gh-31640
2023-11-21 11:22:16 +01:00
Sam Brannen
8a7144ba42
Document how to log @Sql scripts and statements
...
Closes gh-31589
2023-11-10 11:19:38 +01:00
Sam Brannen
6c3a3dc7d9
Polishing
2023-11-10 11:18:26 +01:00
Simon Baslé
42874178ce
Polish RecordApplicationEvents javadoc: add note on captured threads
...
This commit clarifies that the annotation is used to capture events that
are fired from the test `Thread` or descendant threads, since the test
framework uses `InheritableThreadLocal` to store captured events now.
See gh-31079
See gh-30020
2023-11-09 11:07:53 +01:00
yanghaojia
fe14c85ada
Fix link in Javadoc of ConfigurableMockMvcBuilder
...
See gh-31542
2023-11-02 14:25:35 +01:00
Sam Brannen
a5841fede5
Polishing
2023-11-01 16:23:18 +01:00
Stéphane Nicoll
115a46c5e8
Polish
2023-10-31 17:58:13 +01:00
Sam Brannen
3d248607dc
Update copyright headers
2023-10-30 15:21:02 +01:00
Sam Brannen
cb9382d986
Polishing
2023-10-29 10:16:32 +01:00
Sam Brannen
6c4cbd2aab
Support ContextLoader config in @SpringJUnit[Web]Config
...
Prior to this commit, @SpringJUnitConfig and @SpringJUnitWebConfig
did not declare `loader` attributes that alias @ContextConfiguration's
`loader` attribute. Consequently, it was not possible to configure a
custom ContextLoader via those annotations.
The lack of those `loader` attributes was an oversight, and this commit
introduces them to support custom ContextLoader configuration directly
via the @SpringJUnitConfig and @SpringJUnitWebConfig annotations.
Closes gh-31498
2023-10-25 16:12:17 +02:00
Sam Brannen
d7e6b79336
Log and skip resource hint registration for classpath location patterns
...
Since we do not yet have support for registering resource hints for
classpath location patterns, we have decided to explicitly skip such
resources and log a warning to inform users that they need to manually
supply resource hints for the exact resources needed by their
application.
This commit applies this change for @PropertySource and
@TestPropertySource.
See gh-31162
Closes gh-31429
2023-10-25 12:42:36 +02:00
rstoyanchev
e57b942b4d
MockMvcBuilder supports filter name in addition to initParams
...
Closes gh-31474
2023-10-24 10:33:58 +01:00
Sam Brannen
2d792f000a
Polish "Apply SingleSpaceSeparator Checkstyle module"
...
See gh-31469
2023-10-22 14:18:18 +02:00
Johnny Lim
64e9fcad53
Apply SingleSpaceSeparator Checkstyle module
...
This commit also fixes its violations.
Closes gh-31469
2023-10-22 14:09:57 +02:00
Sam Brannen
8a05661707
Polishing
2023-10-22 13:35:49 +02:00
Sam Brannen
f72bf0c177
Revert "Skipping duplicate test classes during test AOT processing"
...
This reverts commit 1281f03b96 .
2023-10-22 13:35:49 +02:00
Sam Brannen
563112c1b7
Ensure integration tests pass in AOT mode
...
See gh-29122
2023-10-22 13:35:49 +02:00
Sam Brannen
37e6fe5b64
Update copyright headers
2023-10-22 11:28:40 +02:00
Brian Clozel
dab7e03c93
Polish
...
See gh-28041
2023-10-20 18:34:52 +02:00
Chen Jianbin
4bf995fa8b
Support "*" mapping in MockMvc filter registration
...
Prior to this commit, configuring a Servlet filter in MockMvc with a
defined mapping would only consider "/*" as a catch-all pattern.
This commit relaxes this rule by also accepting "*" mappings.
Closes gh-28041
2023-10-20 18:32:06 +02:00
Johnny Lim
919faa2ce2
Order modifiers to align with JLS
...
This commit also applies Checkstyle ModifierOrder to enforce it.
See gh-31368
2023-10-17 16:13:56 +02:00
Sam Brannen
1fb2a37957
Apply @DisabledInAotMode for @EJB and SpEL usage
...
Most of the remaining failures are due to @Resource usage.
Current AOT test results for the spring-test module:
Test run finished after 6140 ms
[ 399 containers found ]
[ 64 containers skipped ]
[ 335 containers started ]
[ 0 containers aborted ]
[ 333 containers successful ]
[ 2 containers failed ]
[ 745 tests found ]
[ 116 tests skipped ]
[ 628 tests started ]
[ 1 tests aborted ]
[ 589 tests successful ]
[ 38 tests failed ]
Failing Test Classes:
org.springframework.test.context.groovy.AbsolutePathGroovySpringContextTests
org.springframework.test.context.groovy.GroovySpringContextTests
org.springframework.test.context.groovy.RelativePathGroovySpringContextTests
org.springframework.test.context.jdbc.BeforeTestClassSqlScriptsTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$ConfigOverriddenByDefaultTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.orm.JpaEntityListenerTests
org.springframework.test.context.junit4.AbsolutePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ClassPathResourceSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ConcreteTransactionalJUnit4SpringContextTests
org.springframework.test.context.junit4.InheritedConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.MultipleResourcesSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests
org.springframework.test.context.junit4.RelativePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.SpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.annotation.AnnotationConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.spr9799.Spr9799XmlConfigTests
org.springframework.test.context.testng.ConcreteTransactionalTestNGSpringContextTests
See gh-29122
2023-10-16 21:39:17 +02:00
Sam Brannen
88cd0700b2
Filter out TestNG @EJB tests in AOT end-to-end tests
...
See gh-29122
2023-10-16 21:39:17 +02:00
Sam Brannen
9cac5eeeab
Consistently use generated name in embedded databases
...
... to avoid database name conflicts when test classes are executed in
a different order.
See gh-29122
2023-10-16 21:38:47 +02:00
Sam Brannen
0adec6d15a
Apply @DisabledInAotMode to remaining @ContextHierarchy integration tests
...
See gh-29122
2023-10-16 21:35:57 +02:00
Sam Brannen
bb95f2e5ca
Apply @DisabledInAotMode to @ContextHierarchy integration tests
...
This commit applies @DisabledInAotMode to all integration test classes
in the spring-test module that use @ContextHierarchy since that
feature is not supported for AOT optimizations.
Current AOT test results for the spring-test module:
Test run finished after 6888 ms
[ 403 containers found ]
[ 57 containers skipped ]
[ 346 containers started ]
[ 0 containers aborted ]
[ 338 containers successful ]
[ 8 containers failed ]
[ 757 tests found ]
[ 98 tests skipped ]
[ 654 tests started ]
[ 9 tests aborted ]
[ 576 tests successful ]
[ 69 tests failed ]
Failing Test Classes:
org.springframework.test.context.configuration.interfaces.SqlConfigInterfaceTests
org.springframework.test.context.expression.ExpressionUsageTests
org.springframework.test.context.groovy.AbsolutePathGroovySpringContextTests
org.springframework.test.context.groovy.GroovySpringContextTests
org.springframework.test.context.groovy.RelativePathGroovySpringContextTests
org.springframework.test.context.hierarchies.meta.MetaHierarchyLevelTwoTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithBareContextConfigurationInSubclassTests
org.springframework.test.context.jdbc.CustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.GlobalCustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.InferredDataSourceTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.InfrastructureProxyTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.NonTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsChildTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsParentTests
org.springframework.test.context.jdbc.TransactionalAfterTestMethodSqlScriptsTests
org.springframework.test.context.jdbc.TransactionalInlinedStatementsSqlScriptsTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$ConfigOverriddenByDefaultTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.orm.JpaEntityListenerTests
org.springframework.test.context.junit4.AbsolutePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ClassPathResourceSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ConcreteTransactionalJUnit4SpringContextTests
org.springframework.test.context.junit4.InheritedConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.MultipleResourcesSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests
org.springframework.test.context.junit4.RelativePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.SpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.annotation.AnnotationConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.rules.TransactionalSqlScriptsSpringRuleTests
org.springframework.test.context.junit4.spr9799.Spr9799XmlConfigTests
org.springframework.test.context.testng.ConcreteTransactionalTestNGSpringContextTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.transaction.ejb.CommitForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.CommitForRequiresNewEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiresNewEjbTxDaoTests
See gh-29122
2023-10-16 17:11:00 +02:00
Sam Brannen
44931dca44
Include all failing test classes in AOT end-to-end test report
...
Prior to this commit, AotIntegrationTests only printed "failing test
classes" for tests that failed at the class level.
This commit updates the reporting logic to report test classes for
failing test methods as well.
Current results for the spring-test module:
Test run finished after 6531 ms
[ 403 containers found ]
[ 27 containers skipped ]
[ 376 containers started ]
[ 0 containers aborted ]
[ 366 containers successful ]
[ 10 containers failed ]
[ 757 tests found ]
[ 61 tests skipped ]
[ 689 tests started ]
[ 9 tests aborted ]
[ 585 tests successful ]
[ 95 tests failed ]
Failing Test Classes:
org.springframework.test.context.configuration.interfaces.ContextHierarchyInterfaceTests
org.springframework.test.context.configuration.interfaces.SqlConfigInterfaceTests
org.springframework.test.context.expression.ExpressionUsageTests
org.springframework.test.context.groovy.AbsolutePathGroovySpringContextTests
org.springframework.test.context.groovy.GroovySpringContextTests
org.springframework.test.context.groovy.RelativePathGroovySpringContextTests
org.springframework.test.context.hierarchies.meta.MetaHierarchyLevelTwoTests
org.springframework.test.context.hierarchies.standard.ClassHierarchyWithMergedConfigLevelOneTests
org.springframework.test.context.hierarchies.standard.ClassHierarchyWithMergedConfigLevelTwoTests
org.springframework.test.context.hierarchies.standard.ClassHierarchyWithOverriddenConfigLevelTwoTests
org.springframework.test.context.hierarchies.standard.DirtiesContextWithContextHierarchyTests
org.springframework.test.context.hierarchies.standard.SingleTestClassWithTwoLevelContextHierarchyAndMixedConfigTypesTests
org.springframework.test.context.hierarchies.standard.SingleTestClassWithTwoLevelContextHierarchyTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithBareContextConfigurationInSubclassTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithBareContextConfigurationInSuperclassTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithSingleLevelContextHierarchyAndMixedConfigTypesTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithSingleLevelContextHierarchyTests
org.springframework.test.context.hierarchies.web.ControllerIntegrationTests
org.springframework.test.context.hierarchies.web.DispatcherWacRootWacEarTests
org.springframework.test.context.hierarchies.web.RootWacEarTests
org.springframework.test.context.jdbc.CustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.GlobalCustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.InferredDataSourceTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.InfrastructureProxyTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.NonTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsChildTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsParentTests
org.springframework.test.context.jdbc.TransactionalAfterTestMethodSqlScriptsTests
org.springframework.test.context.jdbc.TransactionalInlinedStatementsSqlScriptsTests
org.springframework.test.context.junit.jupiter.nested.ContextHierarchyNestedTests$NestedTestCaseWithInheritedConfigTests
org.springframework.test.context.junit.jupiter.nested.ContextHierarchyNestedTests$NestedTestCaseWithInheritedConfigTests$DoubleNestedTestCaseWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.ContextHierarchyNestedTests$NestedTestCaseWithInheritedConfigTests$DoubleNestedTestCaseWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$ConfigOverriddenByDefaultTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.orm.JpaEntityListenerTests
org.springframework.test.context.junit4.AbsolutePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ClassPathResourceSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ConcreteTransactionalJUnit4SpringContextTests
org.springframework.test.context.junit4.InheritedConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.MultipleResourcesSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests
org.springframework.test.context.junit4.RelativePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.SpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.annotation.AnnotationConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.rules.TransactionalSqlScriptsSpringRuleTests
org.springframework.test.context.junit4.spr9799.Spr9799XmlConfigTests
org.springframework.test.context.testng.ConcreteTransactionalTestNGSpringContextTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.transaction.ejb.CommitForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.CommitForRequiresNewEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiresNewEjbTxDaoTests
org.springframework.test.web.servlet.samples.client.context.JavaConfigTests
org.springframework.test.web.servlet.samples.client.context.WebAppResourceTests
org.springframework.test.web.servlet.samples.client.context.XmlConfigTests
org.springframework.test.web.servlet.samples.context.JavaConfigTests
org.springframework.test.web.servlet.samples.context.WebAppResourceTests
org.springframework.test.web.servlet.samples.context.XmlConfigTests
See gh-29122
2023-10-16 16:56:20 +02:00
Sam Brannen
32b4f55d92
Update copyright headers
2023-10-16 16:19:55 +02:00
Sam Brannen
119a9ffc3e
Rename test class to NestedTests for AOT integration testing
...
Prior to this commit, the NestedTestCase resulted in errors during our
AOT end-to-end integration tests since it did not comply to our "*Tests"
naming convention.
See gh-29122
2023-10-16 16:19:55 +02:00
Sam Brannen
66e3a7a25c
Apply @DisabledInAotMode to appropriate test classes
...
This commit applies @DisabledInAotMode to test classes in the
spring-test module that will never be able to be processed for AOT
optimizations.
Test classes that fail for reasons that can potentially be addressed in
a future version of the framework have not been annotated with
@DisabledInAotMode.
See gh-29122
2023-10-16 16:19:55 +02:00
Sam Brannen
991afe0939
Fix formatting for @DisabledInAotMode error messages
...
See gh-30834
2023-10-16 16:19:55 +02:00
Sam Brannen
1281f03b96
Skipping duplicate test classes during test AOT processing
...
Although it should not happen in theory, sometimes a test class is
discovered more than once via the TestClassScanner in our integration
tests. When it does happen in our tests, the two Class objects have the
same fully-qualified class name but represent different classes which
leads to failures due to incorrect associations between test class
names and their MergedContextConfiguration.
To address this, this commit modifies TestContextAotGenerator so that
it skips duplicate test class names.
2023-10-16 16:19:55 +02:00
Sam Brannen
28939e4754
Find @DisabledInAotMode on enclosing classes for @Nested tests
...
See gh-30834
2023-10-16 16:19:55 +02:00
Sam Brannen
fc81cc5cda
Polishing
2023-10-16 15:56:12 +02:00
Sam Brannen
41098d52d6
Print test summary for AotIntegrationTests.endToEndTestsForEntireSpringTestModule()
...
Current results for the spring-test module:
Test run finished after 6785 ms
[ 403 containers found ]
[ 6 containers skipped ]
[ 397 containers started ]
[ 0 containers aborted ]
[ 381 containers successful ]
[ 16 containers failed ]
[ 757 tests found ]
[ 41 tests skipped ]
[ 703 tests started ]
[ 9 tests aborted ]
[ 599 tests successful ]
[ 95 tests failed ]
Failing Test Classes:
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.env.ExplicitPropertiesFileTestPropertySourceTests$ClasspathTests$PlaceholderAndClasspathPrefixTests
org.springframework.test.context.env.ExplicitPropertiesFileTestPropertySourceTests$ClasspathTests$PlaceholderTests
org.springframework.test.context.env.ExplicitPropertiesFileTestPropertySourceTests$FileSystemTests$CustomPlaceholderTests
org.springframework.test.context.env.ExplicitPropertiesFileTestPropertySourceTests$FileSystemTests$PlaceholdersFollowedByRelativePathsTests
org.springframework.test.context.env.ExplicitPropertiesFileTestPropertySourceTests$FileSystemTests$UserDirAndCustomPlaceholdersTests
org.springframework.test.web.servlet.samples.client.context.WebAppResourceTests
org.springframework.test.web.servlet.samples.client.context.XmlConfigTests
org.springframework.test.web.servlet.samples.context.WebAppResourceTests
org.springframework.test.web.servlet.samples.context.XmlConfigTests
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests
org.springframework.test.context.junit4.nested.NestedTestsWithSpringRulesTests$NestedTestCase
org.springframework.test.context.junit4.spr9799.Spr9799XmlConfigTests
See gh-29122
2023-10-16 13:13:36 +02:00
Sam Brannen
3ad79e919b
Modify tests so they pass in AOT mode
...
... when run via AotIntegrationTests.endToEndTestsForEntireSpringTestModule().
2023-10-16 13:00:07 +02:00