Class WsdlJavaTestGenerator
- java.lang.Object
-
- com.consol.citrus.generate.AbstractTestGenerator<T>
-
- com.consol.citrus.generate.javadsl.JavaTestGenerator<T>
-
- com.consol.citrus.generate.javadsl.JavaDslTestGenerator<T>
-
- com.consol.citrus.generate.javadsl.MessagingJavaTestGenerator<WsdlJavaTestGenerator>
-
- com.consol.citrus.generate.javadsl.WsdlJavaTestGenerator
-
- All Implemented Interfaces:
TestGenerator<WsdlJavaTestGenerator>,WsdlTestGenerator<WsdlJavaTestGenerator>
public class WsdlJavaTestGenerator extends MessagingJavaTestGenerator<WsdlJavaTestGenerator> implements WsdlTestGenerator<WsdlJavaTestGenerator>
Test generator creates one to many test cases based on operations defined in a XML schema XSD.- Since:
- 2.7.4
- Author:
- Christoph Deppisch
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.consol.citrus.generate.TestGenerator
TestGenerator.GeneratorMode
-
-
Field Summary
-
Fields inherited from class com.consol.citrus.generate.AbstractTestGenerator
log, self
-
-
Constructor Summary
Constructors Constructor Description WsdlJavaTestGenerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcreate()Create tests with this generator.protected com.consol.citrus.message.MessagegenerateInboundMessage(com.consol.citrus.message.Message message)Inbound message generation hook for subclasses.protected com.consol.citrus.message.MessagegenerateOutboundMessage(com.consol.citrus.message.Message message)Outbound message generation hook for subclasses.StringgetNamePrefix()Gets the namePrefix.StringgetNameSuffix()Gets the nameSuffix.StringgetOperation()Gets the operation.StringgetWsdl()Gets the wsdl.voidsetNamePrefix(String namePrefix)Sets the namePrefix.voidsetNameSuffix(String nameSuffix)Sets the nameSuffix.voidsetOperation(String operation)Sets the operation.voidsetWsdl(String wsdl)Sets the wsdl.WsdlJavaTestGeneratorwithInboundMappingFile(String mappingFile)Add inbound XPath expression mappings file to manipulate inbound message content.WsdlJavaTestGeneratorwithInboundMappings(Map<String,String> mappings)Add inbound XPath expression mappings to manipulate inbound message content.WsdlJavaTestGeneratorwithNamePrefix(String prefix)Set the test name prefix to use.WsdlJavaTestGeneratorwithNameSuffix(String suffix)Set the test name suffix to use.WsdlJavaTestGeneratorwithOperation(String operation)Set the wsdl operation to use.WsdlJavaTestGeneratorwithOutboundMappingFile(String mappingFile)Add outbound XPath expression mappings file to manipulate outbound message content.WsdlJavaTestGeneratorwithOutboundMappings(Map<String,String> mappings)Add outbound XPath expression mappings to manipulate outbound message content.WsdlJavaTestGeneratorwithWsdl(String wsdlResource)Set the wsdl schema resource to use.-
Methods inherited from class com.consol.citrus.generate.javadsl.MessagingJavaTestGenerator
addRequestHeader, addResponseHeader, createJavaFileBuilder, getActions, getEndpoint, getReceiveRequestCodeProvider, getReceiveResponseCodeProvider, getSendRequestCodeProvider, getSendResponseCodeProvider, setEndpoint, withEndpoint, withRequest, withResponse
-
Methods inherited from class com.consol.citrus.generate.javadsl.JavaDslTestGenerator
getBaseExtension, getCitrusAnnotation
-
Methods inherited from class com.consol.citrus.generate.javadsl.JavaTestGenerator
createAnnotationBuilder, getBaseType, getMode, getSrcDirectory, setMode, withMode
-
Methods inherited from class com.consol.citrus.generate.AbstractTestGenerator
getAuthor, getCreationDate, getDescription, getFileExtension, getFramework, getMethodName, getName, getPackage, getTargetFile, getTargetPackage, getUpdateDateTime, isDisabled, setAuthor, setDescription, setDisabled, setFileExtension, setFramework, setName, setPackage, setSrcDirectory, setTargetPackage, usePackage, useSrcDirectory, withAuthor, withDescription, withDisabled, withFileExtension, withFramework, withName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.consol.citrus.generate.TestGenerator
getAuthor, getDescription, getFramework, getMode, getName, getTargetPackage, isDisabled, usePackage, useSrcDirectory, withAuthor, withDescription, withDisabled, withFramework, withMode, withName
-
Methods inherited from interface com.consol.citrus.generate.WsdlTestGenerator
withEndpoint
-
-
-
-
Method Detail
-
create
public void create()
Description copied from interface:TestGeneratorCreate tests with this generator.- Specified by:
createin interfaceTestGenerator<WsdlJavaTestGenerator>- Overrides:
createin classJavaTestGenerator<WsdlJavaTestGenerator>
-
generateInboundMessage
protected com.consol.citrus.message.Message generateInboundMessage(com.consol.citrus.message.Message message)
Description copied from class:MessagingJavaTestGeneratorInbound message generation hook for subclasses.- Overrides:
generateInboundMessagein classMessagingJavaTestGenerator<WsdlJavaTestGenerator>- Returns:
-
generateOutboundMessage
protected com.consol.citrus.message.Message generateOutboundMessage(com.consol.citrus.message.Message message)
Description copied from class:MessagingJavaTestGeneratorOutbound message generation hook for subclasses.- Overrides:
generateOutboundMessagein classMessagingJavaTestGenerator<WsdlJavaTestGenerator>- Returns:
-
withWsdl
public WsdlJavaTestGenerator withWsdl(String wsdlResource)
Set the wsdl schema resource to use.- Specified by:
withWsdlin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
wsdlResource-- Returns:
-
withNameSuffix
public WsdlJavaTestGenerator withNameSuffix(String suffix)
Set the test name suffix to use.- Specified by:
withNameSuffixin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
suffix-- Returns:
-
withNamePrefix
public WsdlJavaTestGenerator withNamePrefix(String prefix)
Set the test name prefix to use.- Specified by:
withNamePrefixin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
prefix-- Returns:
-
withOperation
public WsdlJavaTestGenerator withOperation(String operation)
Set the wsdl operation to use.- Specified by:
withOperationin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
operation-- Returns:
-
withInboundMappings
public WsdlJavaTestGenerator withInboundMappings(Map<String,String> mappings)
Add inbound XPath expression mappings to manipulate inbound message content.- Specified by:
withInboundMappingsin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
mappings-- Returns:
-
withOutboundMappings
public WsdlJavaTestGenerator withOutboundMappings(Map<String,String> mappings)
Add outbound XPath expression mappings to manipulate outbound message content.- Specified by:
withOutboundMappingsin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
mappings-- Returns:
-
withInboundMappingFile
public WsdlJavaTestGenerator withInboundMappingFile(String mappingFile)
Add inbound XPath expression mappings file to manipulate inbound message content.- Specified by:
withInboundMappingFilein interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
mappingFile-- Returns:
-
withOutboundMappingFile
public WsdlJavaTestGenerator withOutboundMappingFile(String mappingFile)
Add outbound XPath expression mappings file to manipulate outbound message content.- Specified by:
withOutboundMappingFilein interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Parameters:
mappingFile-- Returns:
-
setWsdl
public void setWsdl(String wsdl)
Sets the wsdl.- Parameters:
wsdl-
-
getWsdl
public String getWsdl()
Gets the wsdl.- Specified by:
getWsdlin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Returns:
-
setNameSuffix
public void setNameSuffix(String nameSuffix)
Sets the nameSuffix.- Parameters:
nameSuffix-
-
getNameSuffix
public String getNameSuffix()
Gets the nameSuffix.- Specified by:
getNameSuffixin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Returns:
-
setNamePrefix
public void setNamePrefix(String namePrefix)
Sets the namePrefix.- Parameters:
namePrefix-
-
getNamePrefix
public String getNamePrefix()
Gets the namePrefix.- Returns:
-
setOperation
public void setOperation(String operation)
Sets the operation.- Parameters:
operation-
-
getOperation
public String getOperation()
Gets the operation.- Specified by:
getOperationin interfaceWsdlTestGenerator<WsdlJavaTestGenerator>- Returns:
-
-