1. 26 4月, 2015 1 次提交
    • S
      Fail if multiple @BootstrapWith's are present · e85e9768
      Sam Brannen 提交于
      Prior to this commit it was possible for two @BootstrapWith annotations
      to be 'present' on a test class -- for example, via competing custom
      composed annotations. However, only one of the annotations will ever be
      used to bootstrap the TestContext Framework. Thus, in such scenarios
      one of the annotations will be silently ignored.
      
      This commit introduces a check for such scenarios. BootstrapUtils'
      resolveTestContextBootstrapper() method now throws an
      IllegalStateException if more than one @BootstrapWith annotation is
      'present' on a given test class.
      
      Issue: SPR-12602
      e85e9768
  2. 25 4月, 2015 4 次提交
  3. 24 4月, 2015 7 次提交
  4. 23 4月, 2015 12 次提交
  5. 22 4月, 2015 9 次提交
    • S
      Add script based templating support · a3159dfb
      Sebastien Deleuze 提交于
      This commit adds support for script based templating. Any templating
      library running on top of a JSR-223 ScriptEngine that implements
      Invocable like Nashorn or JRuby could be used.
      
      For example, in order to render Mustache templates thanks to the Nashorn
      Javascript engine provided with Java 8+, you should declare the following
      configuration:
      
      @Configuration
      @EnableWebMvc
      public class MustacheConfig extends WebMvcConfigurerAdapter {
      
      	@Override
      	public void configureViewResolvers(ViewResolverRegistry registry) {
      		registry.scriptTemplate();
      	}
      
      	@Bean
      	public ScriptTemplateConfigurer configurer() {
      		ScriptTemplateConfigurer configurer = new ScriptTemplateConfigurer();
      		configurer.setEngineName("nashorn");
      		configurer.setScripts("mustache.js");
      		configurer.setRenderObject("Mustache");
      		configurer.setRenderFunction("render");
      		return configurer;
      	}
      }
      
      The XML counterpart is:
      
      <beans>
      	<mvc:annotation-driven />
      
      	<mvc:view-resolvers>
      		<mvc:script-template />
      	</mvc:view-resolvers>
      
      	<mvc:script-template-configurer engine-name="nashorn" render-object="Mustache" render-function="render">
      		<mvc:script location="mustache.js" />
      	</mvc:script-template-configurer>
      </beans>
      
      Tested with:
       - Handlebars running on Nashorn
       - Mustache running on Nashorn
       - React running on Nashorn
       - EJS running on Nashorn
       - ERB running on JRuby
       - String templates running on Jython
      
      Issue: SPR-12266
      a3159dfb
    • R
      Add SpEL based selector to DefaultSubscriptionRegistry · b6327ace
      Rossen Stoyanchev 提交于
      Issue: SPR-12884
      b6327ace
    • S
      Polish ApplicationListenerMethodAdapter · 86733a98
      Sam Brannen 提交于
      86733a98
    • S
      Support n meta-annotation levels on methods in AnnotationUtils · b9b0b78f
      Sam Brannen 提交于
      Prior to this commit, the search algorithm used by the
      findAnnotation(Method, Class) method in AnnotationUtils only found
      direct annotations or direct meta-annotations (i.e., one level of
      meta-annotations).
      
      This commit reworks the search algorithm so that it supports arbitrary
      levels of meta-annotations on methods. To make this possible, a new
      findAnnotation(AnnotatedElement, Class) method has been introduced in
      AnnotationUtils.
      
      This fix also allows for the @Ignore'd tests in
      TransactionalEventListenerTests to be re-enabled.
      
      Issue: SPR-12941
      b9b0b78f
    • S
      Fix broken test in AnnotationUtilsTests · 666d1cec
      Sam Brannen 提交于
      666d1cec
    • S
      Document meta-annotation support in AnnotationUtils · 19a75f2c
      Sam Brannen 提交于
      Issue: SPR-12940
      19a75f2c
    • S
      ed88b7fe
    • S
      Fix typo in exception message · 8a1f9f8a
      Sam Brannen 提交于
      8a1f9f8a
    • S
      Add onTimeout() and onCompletion() callbacks to ResponseBodyEmitter · 713fc5c4
      Sebastien Deleuze 提交于
      Issue: SPR-12939
      713fc5c4
  6. 21 4月, 2015 1 次提交
  7. 20 4月, 2015 6 次提交