Я хочу протестировать WCF на основе класса ClientBase в почтальоне, как мне это сделать?
Адрес конечной точки = "http://xxxxxxxx/xxxxx/TestService.svc
" и bindingConfiguration="BasicHttpBinding_TESTAPI
"
Реализация службыкак показано ниже:
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")] [System.ServiceModel.ServiceContractAttribute(ConfigurationName="TESTFApi.TESTAPI")]
public interface TESTAPI {
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/TESTAPI/TESTReceiver", ReplyAction="http://tempuri.org/TESTAPI/TESTReceiverResponse")]
string TESTReceiver(string xRequest);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public interface TESTAPIChannel : TESTAPI, System.ServiceModel.IClientChannel {
}
public partial class TESTIClient : System.ServiceModel.ClientBase<TESTAPI>, TESTAPI {
public TESTAPIClient() {
}
public TESTAPIClient(string endpointConfigurationName) :
base(endpointConfigurationName) {
}
public TESTAPIClient(string endpointConfigurationName, string remoteAddress) :
base(endpointConfigurationName, remoteAddress) {
}
public TESTAPIClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
base(endpointConfigurationName, remoteAddress) {
}
public TESTAPIClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
base(binding, remoteAddress) {
}
public string TESTReceiver(string xRequest) {
return base.Channel.TESTReceiver(xRequest);
}
}
Я хочу смоделировать вызов в Почтальоне на TESTReceiver (xRequest)