Skip to content
Soap publishers and subscriptions for enqueuer
TypeScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
.gitignore
.npmignore
.travis.yml
LICENSE
README.md
package-lock.json
package.json
tsconfig.json
tslint.json

README.md

Enqueuer SOAP plugin

Install

npm i enqueuer-plugin-soap

Usage Example

subscriptions:
  - name: Soap Server
    type: soap
    port: 9876
    path: /server
    soap:
      wsdl: './examples/wsdl/MyService.wsdl'
      service: MySoapService
      port: MyServicePortType
      operation: MyServiceRQ
    response: 
      applicationResults:
        success: 
          type: Application
publishers:
  - name: Publisher Example
    type: soap
    payload:
      MyServiceRQ:
        attributes:
        Type: MyType
    headers: 
      myheader: Test Header
    soap:
      wsdl: './examples/wsdl/MyService.wsdl'
      service: MySoapService
      port: MyServicePortType
      operation: MyServiceRQ
    options:
      endpoint: 'http://localhost:9876/server'

Proxy Example

The following example shows one publisher, hiting an proxy subscritpion that points to other mocked subcsription:

subscriptions:
  - name: Soap Server
    type: soap
    port: 8765
    path: /server
    soap:
      wsdl: './examples/wsdl/MyService.wsdl'
      service: MySoapService
      port: MyServicePortType
      operation: MyServiceRQ
    response: 
      applicationResults:
        success: 
          type: Application
    onMessageReceived:
      assertions:
        - expect: body.MyServiceRQ.attributes.Type
          toBeEqualTo: `MyType`
        - expect: headers.myheader
          toBeEqualTo: `Test Header`
        - expect: headers.newHeader
          toBeEqualTo: `New Header`
  - name: Soap Proxy
    type: soap-proxy
    port: 9876
    path: /server
    soap:
      wsdl: './examples/wsdl/MyService.wsdl'
      service: MySoapService
      port: MyServicePortType
      operation: MyServiceRQ
    endpoint: 'http://localhost:8765/server'
    onOriginalMessageReceived:
      script: this.redirect.headers.newHeader = 'New Header';
      assertions:
        - expect: body.body.MyServiceRQ.attributes.Type
          toBeEqualTo: `MyType`
        - expect: headers['myheader']
          toBeEqualTo: `Test Header`
    onMessageReceived:
      assertions:
        - expect: body.applicationResults.success.type
          toBeEqualTo: `Application`
publishers:
  - name: Publisher Example
    type: soap
    payload:
      MyServiceRQ:
        attributes:
        Type: MyType
    headers: 
      myheader: Test Header
    soap:
      wsdl: './examples/wsdl/MyService.wsdl'
      service: MySoapService
      port: MyServicePortType
      operation: MyServiceRQ
    options:
      endpoint: 'http://localhost:9876/server'
      preserveWhitespace: true
You can’t perform that action at this time.