Commit Graph

455 Commits

Author SHA1 Message Date
Juergen Hoeller
668f5db582 Consistent use of UTC for DateTime tests
Issue: SPR-13536
2015-10-05 21:31:56 +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
Juergen Hoeller
a23629f60f Context namespace exposes value-separator attribute for property-placeholder element
Issue: SPR-7794
2015-09-23 22:39:23 +02:00
Sam Brannen
54703bf3f8 Introduce ignored, failing tests for SPR-13475
This commit introduces ignored, failing tests that demonstrate that the
@Cache* annotations are not yet supported as merged composed annotations.

Issue: SPR-13475
2015-09-23 00:27:14 -04:00
Sam Brannen
d66f85bd66 Polishing 2015-09-22 15:57:32 -04:00
Juergen Hoeller
fbce18418a Context namespace exposes null-value attribute for property-placeholder element
Issue: SPR-13461
2015-09-21 20:47:03 +02:00
Juergen Hoeller
4dee9cbf62 ConcurrentMapCache.putIfAbsent properly supports nulls
Issue: SPR-13458
2015-09-10 14:02:18 +02:00
Sam Brannen
22e84a87f4 Polish proxy tests 2015-09-08 18:34:47 +02:00
Juergen Hoeller
a8432bc8a1 Tests for enum array with varargs (and related refinements)
Issue: SPR-13328
2015-09-08 11:13:23 +02:00
Juergen Hoeller
811de8e50b AbstractApplicationContext allows for re-refresh and re-close
Issue: SPR-13425
2015-09-04 14:38:23 +02:00
Juergen Hoeller
7118fcff0d MethodValidationInterceptor falls back to invocation attempt with resolved bridge method (for Hibernate Validator 5.2 compatibility)
Issue: SPR-12237
2015-08-27 19:13:29 +02:00
Juergen Hoeller
3430f7623c Consistent detection of meta-annotation attributes via ASM
Issue: SPR-13394
2015-08-25 21:52:11 +02:00
Sam Brannen
f47bbb0d9e Polish tests 2015-08-12 19:35:45 +02:00
Juergen Hoeller
e0f012f32d Removal of redundant JdkVersion checks in the test suite
Issue: SPR-13312
2015-08-12 18:42:36 +02:00
Juergen Hoeller
d8794a1edc Test against EhCache 3.0 M2 (as a JCache provider)
Includes latest dependency updates (Jackson 2.6.1, Jetty 9.3.2, Undertow 1.2.10)

Issue: SPR-13342
2015-08-12 16:16:25 +02:00
Juergen Hoeller
9ef38807e6 Polishing 2015-07-30 19:34:33 +02:00
Juergen Hoeller
1a636b1023 Polishing 2015-07-21 20:33:13 +02:00
Sam Brannen
0153913ef4 Polish and simplify EnableSchedulingTests 2015-07-20 14:55:48 +02:00
Juergen Hoeller
cad0665187 Fixed exception message expectation plus formatting
Issue: SPR-13236
2015-07-20 13:01:14 +02:00
Juergen Hoeller
c3e57dd245 AsyncAnnotationBeanPostProcessor tries to find TaskExecutor by type/name
Issue: SPR-13248
2015-07-17 18:55:46 +02:00
Juergen Hoeller
9f15f347bf Renamed 'name' attribute to 'scopeName' (in order to avoid common override conflicts)
Issue: SPR-13239
2015-07-17 15:23:47 +02:00
Juergen Hoeller
ef781b6353 Fixed default formatters test to reliably work with any system locale
Issue: SPR-13232
2015-07-15 02:18:04 +02:00
Juergen Hoeller
2934256257 Polishing 2015-07-15 00:08:11 +02:00
Juergen Hoeller
f4f508d869 Revisit date-time tests for compatibility with JDK 9 build 72
Issue: SPR-13232
2015-07-14 23:58:30 +02:00
Stephane Nicoll
bf786c3176 Support for multiple events per method
In addition to specifying the event type to listen to via a method
parameter, any @EventListener annotated method can now alternatively
define the event type(s) to listen to via the "classes" attributes (that
is aliased to "value").

Something like

@EventListener({FooEvent.class, BarEvent.class})
public void handleFooBar() { .... }

Issue: SPR-13156
2015-07-08 14:51:07 +02:00
Juergen Hoeller
d7f8fa50be Polishing 2015-06-16 22:01:58 +02:00
Stephane Nicoll
75c88ffbeb Remove deprecated warnings 2015-06-16 15:23:56 +02:00
Juergen Hoeller
c41779f895 AsyncExecutionInterceptor supports Java 8's CompletableFuture as a return type
Issue: SPR-13128
2015-06-15 20:35:48 +02:00
Juergen Hoeller
10cb80a500 Removed superfluous @Ignore import
Issue: SPR-11807
2015-06-15 15:57:10 +02:00
Sam Brannen
60cdfa535e Polish ComponentScanParserScopedProxyTests 2015-06-13 16:09:03 +02:00
Sam Brannen
2d23f42609 Introduce alias for 'value' attribute in @Scope
Issue: SPR-11393
2015-06-13 16:07:29 +02:00
Juergen Hoeller
75edb3979e AspectJExpressionPointcut defensively catches exceptions thrown from ShadowMatch.matchesJoinPoint
Issue: SPR-13102
2015-06-11 14:44:19 +02:00
Juergen Hoeller
b02352d30f Enabled test for AspectJ pointcut matching against lambda-defined bean
Issue: SPR-11807
2015-06-10 15:03:06 +02:00
Stephane Nicoll
b87816ed20 Add ResolvableTypeProvider
Provide a mean to detect the actual ResolvableType based on a instance as
a counter measure to type erasure.

Upgrade the event infrastructure to detect if the event (or the payload)
implements such interface. When this is the case, the return value of
`getResolvableType` is used to validate its generic type against the
method signature of the listener.

Issue: SPR-13069
2015-06-09 10:57:31 +02:00
Stephane Nicoll
e8441edcb7 Remove commons pool 2.x workaround
While working on SPR-12532, an extra IdentityWrapper was added to work
around a backward compatible issue between commons pool 1.x and 2.x. This
issue (POOL-283) has actually been fixed in 2.4 and their IdentityWrapper
is using object equality so our wrapper is in the way.

Looking retrospectively, the code looks all fine without the workaround
and commons pool 2.4 or later so it has been removed.
2015-06-05 16:41:21 +02:00
Juergen Hoeller
869b0bc7ee Create enhanced FactoryBean instance before applying method interceptor (preferably via Objenesis)
Also removes "throws Exception" declaration from ThreadPoolExecutorFactoryBean's getObject method.

Issue: SPR-13095
2015-06-05 00:09:42 +02:00
Juergen Hoeller
d195ad216a Polishing 2015-06-04 23:27:40 +02:00
Juergen Hoeller
9410dff99c AsyncResult allows for exposing an execution exception
Issue: SPR-13076
2015-06-04 23:25:18 +02:00
Sam Brannen
ff8597fa80 Introduce alias for 'value' attribute in @ComponentScan.Filter
Issue: SPR-11393
2015-06-04 15:25:20 -04:00
Sam Brannen
d3b5aeb768 Introduce alias for 'value' attribute in @ImportResource
Issue: SPR-11393
2015-06-03 21:26:43 -04:00
Stephane Nicoll
08c032d9fd Allow Cache annotations to not specify any cache name
Since Spring 4.1, a CacheResolver may be configured to customize the way
the cache(s) to use for a given cache operation are retrieved. Since a
CacheResolver implementation may not use the cache names information at
all, this attribute has been made optional.

However, a fix was still applied, preventing a Cache operation without a
cache name to be defined properly. We now allow this valid use case.

Issue: SPR-13081
2015-06-03 11:42:49 +02:00
Sam Brannen
4dffeeee64 Introduce alias for 'value' attribute in caching annotations
This commit introduces new 'cacheNames' attributes (analogous to the
existing attribute of the same name in @CacheConfig) as aliases for the
'value' attributes in @Cacheable, @CachePut, and @CacheEvict.

In addition, SpringCacheAnnotationParser.getAnnotations() has been
refactored to support synthesized annotations.

Issue: SPR-11393
2015-05-31 22:52:01 +02:00
Stephane Nicoll
0ed9ca097b Customize destruction callback for AutoCloseable beans
Previously, a Bean implementing `AutoCloseable` (or `Closeable`) was
always destroyed regardless of its bean definition. In particular, the
documented way of disabling the destruction callback via an empty String
did not work.

AutoCloseable beans are now treated pretty much as any other bean: we
still use the presence of the interface to optimize the check of a
destroy method and we only auto-discover the method name to invoke if
the inferred mode is enabled.

Issue: SPR-13022
2015-05-20 17:19:42 +02:00
Juergen Hoeller
de893ada2b Compatibility with JSR-354 final (and its new Monetary singleton)
Includes support for currency detection with @NumberFormat.

Issue: SPR-12209
2015-05-20 15:15:29 +02:00
Stephane Nicoll
cf391f5ce1 polish
Remove unused imports
2015-05-19 08:49:01 +02:00
Juergen Hoeller
6418b54f81 DataBinder tries ConversionService if PropertyEditor could not produce required type
Issue: SPR-13042
2015-05-18 23:53:39 +02:00
Juergen Hoeller
02da2e85ee DataBinder allows for adding custom Formatters as alternative to PropertyEditors (including per-field formatters)
Includes a generic FormatterPropertyEditorAdapter plus Number conversion support in TypeConverterDelegate.

Issue: SPR-7773
Issue: SPR-6069
2015-05-12 22:33:18 +02:00
Juergen Hoeller
64a01d64c5 Polishing 2015-05-11 14:42:45 +02:00
Juergen Hoeller
1722fa6678 JSR-223 based StandardScriptFactory (including <lang:std> support)
This commit also completes 4.2 schema variants in spring-context.

Issue: SPR-5215
2015-05-08 23:56:08 +02:00
Sam Brannen
4bf32578b5 Rename MethodBasedEvaluationContextTest to *Tests 2015-05-08 18:44:49 +02:00