Commit Graph

577 Commits

Author SHA1 Message Date
Juergen Hoeller
0445ce6c53 Polishing (backported from master)
(cherry picked from commit 92d78c1)
2016-07-06 17:35:30 +02:00
Juergen Hoeller
6500018730 HtmlUnitRequestBuilder decodes request parameter names (backport)
Issue: SPR-14177
2016-07-02 14:08:24 +02:00
Juergen Hoeller
db4882cea4 Polishing 2016-06-30 21:45:55 +02:00
Juergen Hoeller
833ed7168e Add missing package-info files for common packages
Issue: SPR-14420
(cherry picked from commit 66ec1c1)
2016-06-30 21:43:29 +02:00
Juergen Hoeller
a27200e753 Polishing 2016-05-31 13:27:34 +02:00
Juergen Hoeller
d66186a90b Polishing
(cherry picked from commit 8ddb432)
2016-04-27 21:42:01 +02:00
Juergen Hoeller
b7890ca28e Consistent license header
(cherry picked from commit 537193a)
2016-04-11 21:14:05 +02:00
Juergen Hoeller
0ecbeafd2b Polishing
(cherry picked from commit d2d528d)
2016-04-05 11:42:17 +02:00
Juergen Hoeller
756301b7c5 Polishing
(cherry picked from commit 94cb778)
2016-03-25 23:38:23 +01:00
Juergen Hoeller
2ea7fcde3e Polishing
(cherry picked from commit 9af12d2)
2016-03-24 17:17:58 +01:00
Juergen Hoeller
cafb99a33d Polishing
(cherry picked from commit 028a690)
2016-02-24 17:59:15 +01:00
Juergen Hoeller
9c5cabf4ba Refined ApplicationContextInitializer assignability exception
(cherry picked from commit ca19920)
2016-02-24 17:58:29 +01:00
Juergen Hoeller
9f2b3ca8b8 Polishing
(cherry picked from commit 1899fb3)
2016-02-23 00:05:44 +01:00
Juergen Hoeller
659e44146c Consistent equals implementations across class hierarchies
Issue: SPR-13951
(cherry picked from commit ac44f9e)
2016-02-19 15:56:36 +01:00
Sam Brannen
484dd96606 Throw exception if TxMgr cannot be retrieved for @Transactional test
Prior to this commit, a @Transactional integration test would silently
be executed without a transaction if the transaction manager could not
be retrieved from the application context -- for example, it no such
bean was defined or if multiple beans were present but none satisfied
the qualifier.

This commit addresses this issue by throwing an IllegalStateException
if the PlatformTransactionManager cannot be retrieved for a
@Transactional test.

Issue: SPR-13895
(cherry picked from commit 6d2b9a0136)
2016-02-03 18:18:55 +01:00
Juergen Hoeller
935c0a463e Revised MockMvcResultHandlers logger initialization
Issue: SPR-13802
2015-12-16 21:49:48 +01:00
Juergen Hoeller
997278e3ed Polishing 2015-12-16 20:19:41 +01:00
Rossen Stoyanchev
c8aa48faa9 Add params(MultiValueMap) to MockMvc
Issue: SPR-13801
2015-12-16 11:51:59 -05:00
Juergen Hoeller
11806b9215 Class identity comparisons wherever possible (and further polishing)
Issue: SPR-12926
2015-12-09 12:28:09 +01:00
Juergen Hoeller
4261f34b63 Consistent and lenient HttpMethod resolution across all web modules
Issue: SPR-13776
2015-12-09 12:26:44 +01:00
Juergen Hoeller
40cff5e340 Polishing 2015-12-07 17:30:25 +01:00
Juergen Hoeller
a4f5c46fed MockHttpServletResponse.setIntHeader supports 'Content-Length' header as well
Issue: SPR-13752
2015-12-02 13:36:35 +01:00
Juergen Hoeller
aef6b20626 Removed tests for invalid -1 index (for compatibility with JsonPath 2.1) 2015-11-27 14:11:40 +01:00
Juergen Hoeller
dd647659b3 Rearranged cache test class names across several modules 2015-11-26 16:30:44 +01:00
Juergen Hoeller
fd84262e71 Polishing 2015-11-25 23:09:24 +01:00
Stephane Nicoll
bf1afdfdc9 Add cache tests for JCache 2015-11-24 10:15:09 +01:00
Stephane Nicoll
610b5a20ea Fix test name 2015-11-23 18:22:53 +01:00
Sam Brannen
59d60c60cf Polishing 2015-11-16 01:44:16 +01:00
Sam Brannen
4b682275c9 Clean up warnings in spring-test 2015-11-14 22:57:33 +01:00
Juergen Hoeller
5b901852e6 Upgrade to HtmlUnit 2.19
This upgrade includes AutoCloseable support for HtmlUnit WebConnections as introduced in 2.19, while remaining compatible with 2.18.

Issue: SPR-13686
2015-11-14 15:32:42 +01:00
Rossen Stoyanchev
8c127ad3c9 Property init HandlerMapping in standalone MockMvc
Issue: SPR-13637
2015-11-11 15:14:18 -05:00
Juergen Hoeller
b057e503ef Adapted exception message expectations
Issue: SPR-13621
2015-11-05 18:06:14 +01:00
Hronom
1d60a6a6af Added strict compare mode for Json
Issue: SPR-13607
2015-10-29 17:05:37 +01:00
Rossen Stoyanchev
323fa8510d Call complete() on MockAsyncContext after dispatch
Issue: SPR-13615
2015-10-29 10:12:47 -04:00
Sam Brannen
1bf7249d59 Suppress deprecation warning in HtmlUnitRequestBuilderTests 2015-10-16 19:15:29 +02:00
Juergen Hoeller
66177dfd8c StreamUtils.emptyInput() for consistent empty InputStream exposure
Issue: SPR-13563
2015-10-12 22:25:40 +02:00
Sam Brannen
3db62d5494 Remove MimeTypeResolver since JAF is part of Java SE 6+
The inner MimeTypeResolver class is no longer necessary in the
MockServletContext since the Java Activation Framework (JAF) is a
standard part of Java SE since Java 6.
2015-10-06 15:56:00 +02:00
Sam Brannen
61a46db101 Treat query param w/o "=" as empty string in HtmlUnitRequestBuilder
Prior to this commit, HtmlUnitRequestBuilder stored empty query
parameters declared without an equals sign as null (i.e., query
parameters such as 'error' in 'http://example.com/login?error').

This commit addresses this issue by ensuring that
HtmlUnitRequestBuilder treats all empty query parameter values as empty
strings. Consequently, query strings such as '?error' and '?error=' now
both result in 'error' being stored as an empty string.

Issue: SPR-13524
2015-10-04 19:11:41 +02:00
Sam Brannen
283fc94572 Support null query param values in HtmlUnitRequestBuilder
Prior to this commit, HtmlUnitRequestBuilder would incorrectly attempt
to decode null values for query parameters (i.e., query parameters such
as 'error' in 'http://example.com/login?error') which resulted in a
NullPointerException since URLDecoder.decode() does not support null
values.

This commit fixes this issue by ensuring that HtmlUnitRequestBuilder
only attempts to decode non-null query parameter values.

Issue: SPR-13524
2015-09-30 21:48:14 +02:00
Sam Brannen
d5b4685391 Polish HtmlUnitRequestBuilderTests 2015-09-30 21:48:13 +02:00
Juergen Hoeller
a9fbbc55e6 Polishing 2015-09-28 22:11:10 +02:00
Sam Brannen
d883efcb2a Throw meaningful exception if JUnit 4.9 is not present
SpringJUnit4ClassRunner, SpringClassRule, and SpringMethodRule now
throw an IllegalStateException with a meaningful message if JUnit 4.9
is not present in the classpath (specifically if
org.junit.runners.model.MultipleFailureException cannot be loaded).

Issue: SPR-13521
2015-09-28 20:15:40 +02:00
Sam Brannen
d5ee787e1e Migrate JUnit 3 tests to JUnit 4
This commit migrates all remaining tests from JUnit 3 to JUnit 4, with
the exception of Spring's legacy JUnit 3.8 based testing framework that
is still in use in the spring-orm module.

Issue: SPR-13514
2015-09-27 21:17:51 +02:00
Rossen Stoyanchev
df171ff5bb MockMvc request builder preserves double slashes
The MockHttpServletRequestBuilder now uses java.net.URI internally
rather than UriComponents.

This means that for the MockMvcRequestBuilders method variants that
accept a java.net.URI we can use it as is. The difference is almost
none but it does mean that you can create a URI with double slashes
(for testing purposes) and have it remain that way.

Issue: SPR-13435
2015-09-23 17:50:29 -04:00
Rossen Stoyanchev
fb3e054a31 Update Javadoc
Issue: SPR-13479
2015-09-23 17:29:21 -04:00
Sam Brannen
e2bfbdcfd1 Support attribute overrides with @ResponseStatus
This commit introduces support for attribute overrides for
@ResponseStatus when @ResponseStatus is used as a meta-annotation on
a custom composed annotation.

Specifically, this commit migrates all code that looks up
@ResponseStatus from using AnnotationUtils.findAnnotation() to using
AnnotatedElementUtils.findMergedAnnotation().

Issue: SPR-13441
2015-09-11 21:05:30 +02:00
Juergen Hoeller
bc13cb2af5 Polishing 2015-09-10 14:05:06 +02:00
Sam Brannen
ae8a341a55 Polishing 2015-09-08 18:34:47 +02:00
Juergen Hoeller
52fdfd59ab Polishing 2015-09-08 18:11:30 +02:00
Juergen Hoeller
667fc7e4a9 Polishing 2015-09-04 14:38:47 +02:00