use of uk.gov.justice.services.generators.commons.helper.RestResourceBaseUri in project microservice_framework by CJSCommonPlatform.
the class GeneratorsTest method shouldReturnInterfaceNamePrefixedWithBaseUriPath.
@Test
public void shouldReturnInterfaceNamePrefixedWithBaseUriPath() throws Exception {
final Resource resource = resource("/bcd").withDefaultPostAction().build();
final String interfaceName = resourceInterfaceNameOf(resource, new RestResourceBaseUri("http://localhost:8080/warname/base/path"));
assertThat(interfaceName, is("BasePathBcdResource"));
}
use of uk.gov.justice.services.generators.commons.helper.RestResourceBaseUri in project microservice_framework by CJSCommonPlatform.
the class GeneratorsTest method shouldReturnInterfaceNamePrefixedWithComponentName.
@Test
public void shouldReturnInterfaceNamePrefixedWithComponentName() throws Exception {
final Resource resource = resource("/abc").withDefaultPostAction().build();
final String interfaceName = resourceInterfaceNameOf(resource, new RestResourceBaseUri("http://localhost:8080/warname/command/api/rest/service"));
assertThat(interfaceName, is("CommandApiAbcResource"));
}
Aggregations