cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Beryozkin (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CXF-5091) Leverage Spring's @Configuration mechanism to simplify the creation and configuration of client proxies for integration testing
Date Thu, 30 Apr 2015 16:38:07 GMT

     [ https://issues.apache.org/jira/browse/CXF-5091?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Sergey Beryozkin updated CXF-5091:
----------------------------------
    Fix Version/s:     (was: 3.1.0)

> Leverage Spring's @Configuration mechanism to simplify the creation and configuration
of client proxies for integration testing
> -------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CXF-5091
>                 URL: https://issues.apache.org/jira/browse/CXF-5091
>             Project: CXF
>          Issue Type: New Feature
>          Components: JAX-RS
>            Reporter: Paul Wilson
>            Priority: Minor
>              Labels: client, configuration, spring
>
> Spring's Java-driven application context configuration mechanism "@Configuration" could
be used to simplify system tests by abstracting the creation and configuration of client proxies.

> Spring 3.1 and later ships with a suite of @Enable* annotations that drive the registration
of infrastructure beans within the application context. For example, @EnableWebMvc configures
the application context with the relevant beans for Spring MVC. The @Enable* annotations are
equivalent Spring bean configuration namespace registrations such as <mvc:annotation-driven/>.
> A @EnableCxfRsClientProxy could be employed to simplify the creation and configuration
of a single test client proxy:
> {code}
> public class MyIntegrationTest {
>    @EnableCxfRsClientProxy    
>    @Configuration
>    static class ConfigureFooClientProxy extends CxfRsClientProxyAdapter {
>        @Override
>        public Class<?> getServiceType {
>           return FooService.class;
>        }
>    }
>    @Autowired
>    private FooService clientProxy;
>    @Test
>    public void should() {
>    }
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message