Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug/#537 fix account creation issue #217

Merged

Conversation

shashi165
Copy link
Contributor

@shashi165 shashi165 commented Dec 4, 2018

Fix for the bug #537

lodash vulnerability Issue

1. while account creation changed the participantCurrency.isActive = false
2. after setting up the initial position and limits changed the participantCurrency.isActive = true
3. upgraded the version of lodash to fix the vulnerability issues

Unit Tests

1..1005
# tests 1005
# pass  1005

# ok

Coverage Tests

=============================== Coverage summary ===============================
Statements   : 97.9% ( 2842/2903 )
Branches     : 95.49% ( 677/709 )
Functions    : 97.3% ( 397/408 )
Lines        : 97.95% ( 2815/2874 )
================================================================================

Integration Tests

View Results

<?xml version="1.0"?>
<testsuites>
  <testsuite tests="0" failures="0" errors="0" name="Participant service"/>
  <testsuite tests="1" failures="0" errors="0" name="setup">
    <testcase name="#1 setup OK"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="create participant"/>
  <testsuite tests="0" failures="0" errors="0" name="getByName"/>
  <testsuite tests="0" failures="0" errors="0" name="getAll"/>
  <testsuite tests="0" failures="0" errors="0" name="Testing with participant"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantId&quot;: 2,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;name&quot;: &quot;fsp169116425&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;description&quot;: null,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;isActive&quot;: 1,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:11:56.000Z&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdBy&quot;: &quot;unknown&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;currencyList&quot;: ["/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantCurrencyId&quot;: 1,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantId&quot;: 2,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;currencyId&quot;: &quot;USD&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;ledgerAccountTypeId&quot;: 1,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;isActive&quot;: 0,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:11:56.000Z&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdBy&quot;: &quot;unknown&quot;"/>
  <testsuite tests="0" failures="0" errors="0" name="},"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantCurrencyId&quot;: 2,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantId&quot;: 2,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;currencyId&quot;: &quot;USD&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;ledgerAccountTypeId&quot;: 2,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;isActive&quot;: 0,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:11:56.000Z&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdBy&quot;: &quot;unknown&quot;"/>
  <testsuite tests="0" failures="0" errors="0" name="}"/>
  <testsuite tests="0" failures="0" errors="0" name="]"/>
  <testsuite tests="4" failures="0" errors="0" name="}">
    <testcase name="#2 names are equal"/>
    <testcase name="#3 currency match"/>
    <testcase name="#4 isActive flag matches"/>
    <testcase name="#5 created date matches"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Testing with participant"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantId&quot;: 3,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;name&quot;: &quot;fsp269116737&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;description&quot;: null,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;isActive&quot;: 1,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:11:56.000Z&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdBy&quot;: &quot;unknown&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;currencyList&quot;: ["/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantCurrencyId&quot;: 3,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantId&quot;: 3,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;currencyId&quot;: &quot;USD&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;ledgerAccountTypeId&quot;: 1,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;isActive&quot;: 0,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:11:56.000Z&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdBy&quot;: &quot;unknown&quot;"/>
  <testsuite tests="0" failures="0" errors="0" name="},"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantCurrencyId&quot;: 4,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantId&quot;: 3,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;currencyId&quot;: &quot;USD&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;ledgerAccountTypeId&quot;: 2,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;isActive&quot;: 0,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:11:56.000Z&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdBy&quot;: &quot;unknown&quot;"/>
  <testsuite tests="0" failures="0" errors="0" name="}"/>
  <testsuite tests="0" failures="0" errors="0" name="]"/>
  <testsuite tests="9" failures="0" errors="0" name="}">
    <testcase name="#6 names are equal"/>
    <testcase name="#7 currency match"/>
    <testcase name="#8 isActive flag matches"/>
    <testcase name="#9 created date matches"/>
    <testcase name="#10 names are equal"/>
    <testcase name="#11 currencies match"/>
    <testcase name="#12 isActive flag matches"/>
    <testcase name="#13 created date matches"/>
    <testcase name="#14 returns result"/>
  </testsuite>
  <testsuite tests="6" failures="0" errors="0" name="getById">
    <testcase name="#15 names are equal"/>
    <testcase name="#16 currencies match"/>
    <testcase name="#17 isActive flag matches"/>
    <testcase name="#18 created date matches"/>
    <testcase name="#19 should be equal"/>
    <testcase name="#20 should be equal"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="add participant endpoint"/>
  <testsuite tests="0" failures="0" errors="0" name="getEndpoint"/>
  <testsuite tests="0" failures="0" errors="0" name="getAllEndpoints"/>
  <testsuite tests="3" failures="0" errors="0" name="First endpoint">
    <testcase name="#21 endpoint types are equal"/>
    <testcase name="#22 endpoint values match"/>
    <testcase name="#23 isActive flag match"/>
  </testsuite>
  <testsuite tests="3" failures="0" errors="0" name="Second endpoint">
    <testcase name="#24 endpoint types are equal"/>
    <testcase name="#25 endpoint values match"/>
    <testcase name="#26 isActive flag match"/>
  </testsuite>
  <testsuite tests="11" failures="0" errors="0" name="destroyPariticpantEndpointByName">
    <testcase name="#27 endpoint types are equal"/>
    <testcase name="#28 endpoint values match"/>
    <testcase name="#29 endpoint types are equal"/>
    <testcase name="#30 endpoint values match"/>
    <testcase name="#31 isActive flag match"/>
    <testcase name="#32 endpoint types are equal"/>
    <testcase name="#33 endpoint values match"/>
    <testcase name="#34 endpoint types are equal"/>
    <testcase name="#35 endpoint values match"/>
    <testcase name="#36 isActive flag match"/>
    <testcase name="#37 destroy endpoint for fsp169116425 success"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="add participant limit and initial position">
    <testcase name="#38 addLimitAndInitialPosition successful for Participant: fsp169116425"/>
  </testsuite>
  <testsuite tests="2" failures="0" errors="0" name="update limits">
    <testcase name="#39 adjustLimits successful for Participant: fsp169116425"/>
    <testcase name="#40 The limits updated successfully"/>
  </testsuite>
  <testsuite tests="2" failures="0" errors="0" name="get participant position">
    <testcase name="#41 currencies are equal"/>
    <testcase name="#42 position value match"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="destroy participant position">
    <testcase name="#43 destroy participant position for fsp169116425 success"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="destroy participant limits">
    <testcase name="#44 destroy participant limits for fsp169116425 success"/>
  </testsuite>
  <testsuite tests="4" failures="0" errors="0" name="update">
    <testcase name="#45 ids match"/>
    <testcase name="#46 update works"/>
    <testcase name="#47 ids match"/>
    <testcase name="#48 update works"/>
  </testsuite>
  <testsuite tests="2" failures="0" errors="0" name="teardown">
    <testcase name="#49 destroy fsp169116425 success"/>
    <testcase name="#50 destroy fsp269116737 success">
      <system-out>2018-12-04T19:11:58.017Z - [32minfo[39m: CreateHandle::connect successful topic: topic-transfer-fulfil
</system-out>
    </testcase>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Handlers test"/>
  <testsuite tests="0" failures="0" errors="0" name="registerAllHandlers should"/>
  <testsuite tests="1" failures="0" errors="0" name="setup handlers">
    <testcase name="#51 done">
      <system-out>2018-12-04T19:12:14.926Z - [32minfo[39m: Registering prepareHandler for Participant: payer69134026
</system-out>
      <system-out>2018-12-04T19:12:15.135Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payer69134026-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:12:15.136Z - [32minfo[39m: Registering prepareHandler for Participant: payee69134393
</system-out>
      <system-out>2018-12-04T19:12:15.342Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payee69134393-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:12:15.446Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payer69134026-position-abort,topic-payer69134026-position-fulfil,topic-payer69134026-position-prepare
</system-out>
      <system-out>2018-12-04T19:12:16.339Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payee69134393-position-abort,topic-payee69134393-position-fulfil,topic-payee69134393-position-prepare
</system-out>
      <system-out>2018-12-04T19:12:20.346Z - [32minfo[39m: Producer::start::topic=topic-payer69134026-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:12:20.347Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:12:21.476Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:12:21.477Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"id":"739e2166-d1b0-4463-81b7-9379269f04b7","from":"payer69134026","to":"payee69134393","type":"application/json","content":{"header":"","payload":{"transferId":"739e2166-d1b0-4463-81b7-9379269f04b7","payerFsp":"payer69134026","payeeFsp":"payee69134393","amount":{"currency":"USD","amount":110},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"metadata":{"event":{"id":"6584ed80-dea1-424e-9a86-25948c95e1d7","type":"prepare","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0}}},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:21.477Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:12:21.576Z - [32minfo[39m: TransferService::prepare
</system-out>
      <system-out>2018-12-04T19:12:21.576Z - [32minfo[39m: TransferService::prepare::checking for duplicates
</system-out>
      <system-out>2018-12-04T19:12:21.631Z - [32minfo[39m: TransferService::prepare::validationPassed
</system-out>
      <system-out>2018-12-04T19:12:21.631Z - [32minfo[39m: TransferService::prepare::validationPassed::newEntry
</system-out>
      <system-out>2018-12-04T19:12:21.824Z - [32minfo[39m: TransferService::prepare::validationPassed::create position topic
</system-out>
      <system-out>2018-12-04T19:12:21.825Z - [32minfo[39m: Producer::start::topic=topic-payer69134026-position-prepare
</system-out>
      <system-out>2018-12-04T19:12:21.826Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:12:22.550Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:12:22.551Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69134026","to":"payee69134393","id":"739e2166-d1b0-4463-81b7-9379269f04b7","content":{"header":"","payload":{"transferId":"739e2166-d1b0-4463-81b7-9379269f04b7","payerFsp":"payer69134026","payeeFsp":"payee69134393","amount":{"currency":"USD","amount":110},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"type":"application/json","metadata":{"event":{"id":"1ed212c5-305c-43ef-92ea-c295fbd2ff6c","type":"position","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"6584ed80-dea1-424e-9a86-25948c95e1d7"},"protocol.createdAt":1543950741477},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:22.551Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:12:22.555Z - [32minfo[39m: PositionHandler::positions
</system-out>
      <system-out>2018-12-04T19:12:22.555Z - [32minfo[39m: PositionHandler::positions::prepare
</system-out>
      <system-out>2018-12-04T19:12:22.702Z - [32minfo[39m: Producer::start::topic=topic-notification-event
</system-out>
      <system-out>2018-12-04T19:12:22.702Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:12:23.678Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:12:23.678Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69134026","to":"payee69134393","id":"739e2166-d1b0-4463-81b7-9379269f04b7","content":{"header":"","payload":{"transferId":"739e2166-d1b0-4463-81b7-9379269f04b7","payerFsp":"payer69134026","payeeFsp":"payee69134393","amount":{"currency":"USD","amount":110},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"type":"application/json","metadata":{"event":{"id":"1372297c-3ac3-47b5-a9a7-0c55d4e90996","type":"notification","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"1ed212c5-305c-43ef-92ea-c295fbd2ff6c"},"protocol.createdAt":1543950742551},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:23.678Z - [32minfo[39m: Producer::end
</system-out>
    </testcase>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="transferFulfilCommit should"/>
  <testsuite tests="5" failures="0" errors="0" name="update transfer state to RESERVED by PREPARE request">
    <testcase name="#52 Producer for prepare published message"/>
    <testcase name="#53 Transfer state changed to RESERVED"/>
    <testcase name="#54 Payer position incremented by transfer amount and updated in participantPosition"/>
    <testcase name="#55 Payer position change value inserted and matches the updated participantPosition value"/>
    <testcase name="#56 Payer position change record is bound to the corresponding transfer state change">
      <system-out>2018-12-04T19:12:29.486Z - [32minfo[39m: Producer::start::topic=topic-transfer-fulfil
</system-out>
      <system-out>2018-12-04T19:12:29.486Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:12:29.877Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:12:29.877Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"id":"739e2166-d1b0-4463-81b7-9379269f04b7","from":"payer69134026","to":"payee69134393","type":"application/json","content":{"header":"","payload":{"fulfilment":"UNlJ98hZTY_dsw0cAqw4i_UN3v4utt7CZFB4yfLbVFA","completedTimestamp":"2018-12-04T19:11:56.353Z","transferState":"COMMITTED","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"metadata":{"event":{"id":"3f14e7e5-c0e7-4f41-ba55-29a7298326a7","type":"fulfil","action":"commit","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0}}},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:29.877Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:12:29.881Z - [32minfo[39m: FulfilHandler::commit
</system-out>
      <system-out>2018-12-04T19:12:29.885Z - [32minfo[39m: FulfilHandler::commit::validationPassed
</system-out>
      <system-out>2018-12-04T19:12:30.226Z - [32minfo[39m: Producer::start::topic=topic-payee69134393-position-fulfil
</system-out>
      <system-out>2018-12-04T19:12:30.226Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:12:30.815Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:12:30.815Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69134026","to":"payee69134393","id":"739e2166-d1b0-4463-81b7-9379269f04b7","content":{"header":"","payload":{"fulfilment":"UNlJ98hZTY_dsw0cAqw4i_UN3v4utt7CZFB4yfLbVFA","completedTimestamp":"2018-12-04T19:11:56.353Z","transferState":"COMMITTED","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"type":"application/json","metadata":{"event":{"id":"c62f6809-7176-49f3-8f5d-b5e3a92d5631","type":"position","action":"commit","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"3f14e7e5-c0e7-4f41-ba55-29a7298326a7"},"protocol.createdAt":1543950749877},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:30.815Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:12:30.818Z - [32minfo[39m: PositionHandler::positions
</system-out>
      <system-out>2018-12-04T19:12:30.818Z - [32minfo[39m: PositionHandler::positions::commit
</system-out>
      <system-out>2018-12-04T19:12:30.820Z - [32minfo[39m: PositionHandler::positions::commit::validationPassed
</system-out>
      <system-out>2018-12-04T19:12:30.958Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69134026","to":"payee69134393","id":"739e2166-d1b0-4463-81b7-9379269f04b7","content":{"header":"","payload":{"fulfilment":"UNlJ98hZTY_dsw0cAqw4i_UN3v4utt7CZFB4yfLbVFA","completedTimestamp":"2018-12-04T19:11:56.353Z","transferState":"COMMITTED","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]},"transferId":"739e2166-d1b0-4463-81b7-9379269f04b7"}},"type":"application/json","metadata":{"event":{"id":"e9b78507-7853-47f6-af7a-9c2b2e4f1b9b","type":"notification","action":"commit","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"c62f6809-7176-49f3-8f5d-b5e3a92d5631"},"protocol.createdAt":1543950750815},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:30.958Z - [32minfo[39m: Producer::end
</system-out>
    </testcase>
  </testsuite>
  <testsuite tests="6" failures="0" errors="0" name="update transfer state to COMMITTED by FULFIL request">
    <testcase name="#57 Producer for fulfil published message"/>
    <testcase name="#58 Transfer state changed to COMMITTED"/>
    <testcase name="#59 Commit ilpFulfilment saved"/>
    <testcase name="#60 Payee position decremented by transfer amount and updated in participantPosition"/>
    <testcase name="#61 Payee position change value inserted and matches the updated participantPosition value"/>
    <testcase name="#62 Payee position change record is bound to the corresponding transfer state change">
      <system-out>2018-12-04T19:12:38.747Z - [32minfo[39m: Registering prepareHandler for Participant: payer69157885
</system-out>
      <system-out>2018-12-04T19:12:39.046Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payer69157885-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:12:39.047Z - [32minfo[39m: Registering prepareHandler for Participant: payee69158260
</system-out>
      <system-out>2018-12-04T19:12:40.053Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payee69158260-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:12:41.681Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payer69157885-position-abort,topic-payer69157885-position-fulfil,topic-payer69157885-position-prepare
</system-out>
      <system-out>2018-12-04T19:12:43.838Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payee69158260-position-abort,topic-payee69158260-position-fulfil,topic-payee69158260-position-prepare
</system-out>
      <system-out>2018-12-04T19:12:47.841Z - [32minfo[39m: Producer::start::topic=topic-payer69157885-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:12:47.841Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:12:49.843Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:12:49.844Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"id":"98a352c8-052f-4bbc-a26f-c587e2d90167","from":"payer69157885","to":"payee69158260","type":"application/json","content":{"header":"","payload":{"transferId":"98a352c8-052f-4bbc-a26f-c587e2d90167","payerFsp":"payer69157885","payeeFsp":"payee69158260","amount":{"currency":"USD","amount":15},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"metadata":{"event":{"id":"b132618d-42fd-418d-a78c-e3f83dbf86e8","type":"prepare","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0}}},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:49.844Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:12:49.847Z - [32minfo[39m: TransferService::prepare
</system-out>
      <system-out>2018-12-04T19:12:49.847Z - [32minfo[39m: TransferService::prepare::checking for duplicates
</system-out>
      <system-out>2018-12-04T19:12:49.934Z - [32minfo[39m: TransferService::prepare::validationPassed
</system-out>
      <system-out>2018-12-04T19:12:49.934Z - [32minfo[39m: TransferService::prepare::validationPassed::newEntry
</system-out>
      <system-out>2018-12-04T19:12:50.321Z - [32minfo[39m: TransferService::prepare::validationPassed::create position topic
</system-out>
      <system-out>2018-12-04T19:12:50.321Z - [32minfo[39m: Producer::start::topic=topic-payer69157885-position-prepare
</system-out>
      <system-out>2018-12-04T19:12:50.321Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:12:52.387Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:12:52.388Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69157885","to":"payee69158260","id":"98a352c8-052f-4bbc-a26f-c587e2d90167","content":{"header":"","payload":{"transferId":"98a352c8-052f-4bbc-a26f-c587e2d90167","payerFsp":"payer69157885","payeeFsp":"payee69158260","amount":{"currency":"USD","amount":15},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"type":"application/json","metadata":{"event":{"id":"b5e59957-1d1a-42fe-819a-77e99719299f","type":"position","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"b132618d-42fd-418d-a78c-e3f83dbf86e8"},"protocol.createdAt":1543950769844},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:52.388Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:12:52.392Z - [32minfo[39m: PositionHandler::positions
</system-out>
      <system-out>2018-12-04T19:12:52.392Z - [32minfo[39m: PositionHandler::positions::prepare
</system-out>
      <system-out>2018-12-04T19:12:52.536Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69157885","to":"payee69158260","id":"98a352c8-052f-4bbc-a26f-c587e2d90167","content":{"header":"","payload":{"transferId":"98a352c8-052f-4bbc-a26f-c587e2d90167","payerFsp":"payer69157885","payeeFsp":"payee69158260","amount":{"currency":"USD","amount":15},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"type":"application/json","metadata":{"event":{"id":"39b85530-e95b-454d-ae7d-c6e326cbc02a","type":"notification","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"b5e59957-1d1a-42fe-819a-77e99719299f"},"protocol.createdAt":1543950772388},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:52.536Z - [32minfo[39m: Producer::end
</system-out>
    </testcase>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="transferFulfilReject should"/>
  <testsuite tests="2" failures="0" errors="0" name="update transfer state to RESERVED by PREPARE request">
    <testcase name="#63 Producer for prepare published message"/>
    <testcase name="#64 Transfer state changed to RESERVED">
      <system-out>2018-12-04T19:12:57.850Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"id":"98a352c8-052f-4bbc-a26f-c587e2d90167","from":"payer69157885","to":"payee69158260","type":"application/json","content":{"header":"","payload":{"fulfilment":"UNlJ98hZTY_dsw0cAqw4i_UN3v4utt7CZFB4yfLbVFA","completedTimestamp":"2018-12-04T19:11:56.353Z","transferState":"ABORTED","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"metadata":{"event":{"id":"0b49b019-6ac6-44bf-9568-82371de8716e","type":"fulfil","action":"reject","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0}}},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:12:57.850Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:12:57.852Z - [32minfo[39m: FulfilHandler::reject
</system-out>
      <system-out>2018-12-04T19:12:57.857Z - [32minfo[39m: FulfilHandler::reject::validationPassed
</system-out>
      <system-out>2018-12-04T19:12:58.190Z - [32minfo[39m: Producer::start::topic=topic-payer69157885-position-abort
</system-out>
      <system-out>2018-12-04T19:12:58.190Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:13:00.395Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:13:00.395Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69157885","to":"payee69158260","id":"98a352c8-052f-4bbc-a26f-c587e2d90167","content":{"header":"","payload":{"fulfilment":"UNlJ98hZTY_dsw0cAqw4i_UN3v4utt7CZFB4yfLbVFA","completedTimestamp":"2018-12-04T19:11:56.353Z","transferState":"ABORTED","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"type":"application/json","metadata":{"event":{"id":"e9a3c768-1b3e-4078-9116-27fad2b52d70","type":"position","action":"reject","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"0b49b019-6ac6-44bf-9568-82371de8716e"},"protocol.createdAt":1543950777850},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:13:00.395Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:13:00.398Z - [32minfo[39m: PositionHandler::positions
</system-out>
      <system-out>2018-12-04T19:13:00.398Z - [32minfo[39m: PositionHandler::positions::reject
</system-out>
      <system-out>2018-12-04T19:13:00.400Z - [32minfo[39m: PositionHandler::positions::reject::validationPassed
</system-out>
      <system-out>2018-12-04T19:13:00.471Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69157885","to":"payee69158260","id":"98a352c8-052f-4bbc-a26f-c587e2d90167","content":{"header":"","payload":{"fulfilment":"UNlJ98hZTY_dsw0cAqw4i_UN3v4utt7CZFB4yfLbVFA","completedTimestamp":"2018-12-04T19:11:56.353Z","transferState":"ABORTED","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]},"transferId":"98a352c8-052f-4bbc-a26f-c587e2d90167"}},"type":"application/json","metadata":{"event":{"id":"6e1a6fca-227d-405a-8d9d-49c4c1c373bc","type":"notification","action":"reject","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"e9a3c768-1b3e-4078-9116-27fad2b52d70"},"protocol.createdAt":1543950780395},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:13:00.471Z - [32minfo[39m: Producer::end
</system-out>
    </testcase>
  </testsuite>
  <testsuite tests="6" failures="0" errors="0" name="update transfer state to ABORTED by ABORT request">
    <testcase name="#65 Producer for fulfil published message"/>
    <testcase name="#66 Transfer state changed to ABORTED"/>
    <testcase name="#67 Reject ilpFulfilment saved"/>
    <testcase name="#68 Payer position decremented by transfer amount and updated in participantPosition"/>
    <testcase name="#69 Payer position change value inserted and matches the updated participantPosition value"/>
    <testcase name="#70 Payer position change record is bound to the corresponding transfer state change">
      <system-out>2018-12-04T19:13:06.653Z - [32minfo[39m: Registering prepareHandler for Participant: payer69185858
</system-out>
      <system-out>2018-12-04T19:13:08.854Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payer69185858-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:13:08.854Z - [32minfo[39m: Registering prepareHandler for Participant: payee69186079
</system-out>
      <system-out>2018-12-04T19:13:11.845Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payee69186079-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:13:15.362Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payer69185858-position-abort,topic-payer69185858-position-fulfil,topic-payer69185858-position-prepare
</system-out>
      <system-out>2018-12-04T19:13:19.873Z - [32minfo[39m: CreateHandle::connect successful topic: topic-payee69186079-position-abort,topic-payee69186079-position-fulfil,topic-payee69186079-position-prepare
</system-out>
      <system-out>2018-12-04T19:13:23.874Z - [32minfo[39m: Producer::start::topic=topic-payer69185858-transfer-prepare
</system-out>
      <system-out>2018-12-04T19:13:23.874Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:13:26.877Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:13:26.877Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"id":"60fde20c-c5c1-45b4-8b6b-a54579f36fc0","from":"payer69185858","to":"payee69186079","type":"application/json","content":{"header":"","payload":{"transferId":"60fde20c-c5c1-45b4-8b6b-a54579f36fc0","payerFsp":"payer69185858","payeeFsp":"payee69186079","amount":{"currency":"USD","amount":1100},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"metadata":{"event":{"id":"d0c1d2c3-f4a8-4948-a525-0eb67aa320fb","type":"prepare","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0}}},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:13:26.877Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:13:26.880Z - [32minfo[39m: TransferService::prepare
</system-out>
      <system-out>2018-12-04T19:13:26.880Z - [32minfo[39m: TransferService::prepare::checking for duplicates
</system-out>
      <system-out>2018-12-04T19:13:26.956Z - [32minfo[39m: TransferService::prepare::validationPassed
</system-out>
      <system-out>2018-12-04T19:13:26.956Z - [32minfo[39m: TransferService::prepare::validationPassed::newEntry
</system-out>
      <system-out>2018-12-04T19:13:27.153Z - [32minfo[39m: TransferService::prepare::validationPassed::create position topic
</system-out>
      <system-out>2018-12-04T19:13:27.153Z - [32minfo[39m: Producer::start::topic=topic-payer69185858-position-prepare
</system-out>
      <system-out>2018-12-04T19:13:27.153Z - [32minfo[39m: Producer::connect::start
</system-out>
      <system-out>2018-12-04T19:13:31.881Z - [32minfo[39m: Producer::connect::end
</system-out>
      <system-out>2018-12-04T19:13:31.881Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69185858","to":"payee69186079","id":"60fde20c-c5c1-45b4-8b6b-a54579f36fc0","content":{"header":"","payload":{"transferId":"60fde20c-c5c1-45b4-8b6b-a54579f36fc0","payerFsp":"payer69185858","payeeFsp":"payee69186079","amount":{"currency":"USD","amount":1100},"ilpPacket":"AYIBgQAAAAAAAASwNGxldmVsb25lLmRmc3AxLm1lci45T2RTOF81MDdqUUZERmZlakgyOVc4bXFmNEpLMHlGTFGCAUBQU0svMS4wCk5vbmNlOiB1SXlweUYzY3pYSXBFdzVVc05TYWh3CkVuY3J5cHRpb246IG5vbmUKUGF5bWVudC1JZDogMTMyMzZhM2ItOGZhOC00MTYzLTg0NDctNGMzZWQzZGE5OGE3CgpDb250ZW50LUxlbmd0aDogMTM1CkNvbnRlbnQtVHlwZTogYXBwbGljYXRpb24vanNvbgpTZW5kZXItSWRlbnRpZmllcjogOTI4MDYzOTEKCiJ7XCJmZWVcIjowLFwidHJhbnNmZXJDb2RlXCI6XCJpbnZvaWNlXCIsXCJkZWJpdE5hbWVcIjpcImFsaWNlIGNvb3BlclwiLFwiY3JlZGl0TmFtZVwiOlwibWVyIGNoYW50XCIsXCJkZWJpdElkZW50aWZpZXJcIjpcIjkyODA2MzkxXCJ9IgA","condition":"GRzLaTP7DJ9t4P-a_BA0WA9wzzlsugf00-Tn6kESAfM","expiration":"2018-12-05T19:11:56.353Z","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}},"type":"application/json","metadata":{"event":{"id":"7b24ea24-8385-42b2-b381-527c470a401d","type":"position","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"success","code":0,"description":"action successful"},"responseTo":"d0c1d2c3-f4a8-4948-a525-0eb67aa320fb"},"protocol.createdAt":1543950806877},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:13:31.881Z - [32minfo[39m: Producer::end
</system-out>
      <system-out>2018-12-04T19:13:34.875Z - [32minfo[39m: PositionHandler::positions
</system-out>
      <system-out>2018-12-04T19:13:34.875Z - [32minfo[39m: PositionHandler::positions::prepare
</system-out>
      <system-out>2018-12-04T19:13:35.027Z - [32minfo[39m: Producer.sendMessage:: messageProtocol:'{"from":"payer69185858","to":"payee69186079","id":"60fde20c-c5c1-45b4-8b6b-a54579f36fc0","content":{"header":"","payload":{"errorInformation":{"errorCode":4001,"errorDescription":"Payer FSP has insufficient liquidity to perform the transfer","extensionList":{"extension":[{"key":"key1","value":"value1"},{"key":"key2","value":"value2"}]}}}},"type":"application/json","metadata":{"event":{"id":"5057a310-d1a1-4c5e-a1f9-25f64b0181da","type":"notification","action":"prepare","createdAt":"2018-12-04T19:11:56.353Z","state":{"status":"error","code":4001,"description":"Payer FSP has insufficient liquidity to perform the transfer"},"responseTo":"7b24ea24-8385-42b2-b381-527c470a401d"},"protocol.createdAt":1543950811881},"pp":""}'
</system-out>
      <system-out>2018-12-04T19:13:35.028Z - [32minfo[39m: Producer::end
</system-out>
    </testcase>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="transferPrepareExceedLimit should"/>
  <testsuite tests="2" failures="0" errors="0" name="fail the transfer if the amount is higher than the remaining participant limit">
    <testcase name="#71 Producer for prepare published message"/>
    <testcase name="#72 Transfer state changed to ABORTED"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Transfer read model test"/>
  <testsuite tests="1" failures="0" errors="0" name="setup">
    <testcase name="#73 setup OK"/>
  </testsuite>
  <testsuite tests="2" failures="0" errors="0" name="get the created transfer test">
    <testcase name="#74 one or more transfers are returned"/>
    <testcase name="#75 should be equal"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="get the created transfer change test">
    <testcase name="#76 created and read transfer are equal"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Ilp service tests"/>
  <testsuite tests="1" failures="0" errors="0" name="setup">
    <testcase name="#77 setup OK"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="create ilp"/>
  <testsuite tests="0" failures="0" errors="0" name="Testing with ilp"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferId&quot;: &quot;1&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;value&quot;: &quot;test packet&quot;"/>
  <testsuite tests="2" failures="0" errors="0" name="}">
    <testcase name="#78 transferId match"/>
    <testcase name="#79 packet match"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create ilp without transferId should throw error">
    <testcase name="#80 insert into `ilpPacket` (`transferId`, `value`) values (DEFAULT, 'test packet') - ER_NO_DEFAULT_FOR_FIELD: Field 'transferId' doesn't have a default value"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create ilp without packet should throw error">
    <testcase name="#81 insert into `ilpPacket` (`transferId`, `value`) values ('10', DEFAULT) - ER_NO_DEFAULT_FOR_FIELD: Field 'value' doesn't have a default value"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="getByTransferId">
    <testcase name="#82 should be equal"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Testing with ilp"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferId&quot;: &quot;3a87cabc-0503-4765-86e6-16121e0198b7&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;value&quot;: &quot;ILP Packet Value&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:13:44.000Z&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantPayer&quot;: {"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;name&quot;: &quot;payer69224469&quot;"/>
  <testsuite tests="0" failures="0" errors="0" name="},"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;participantPayee&quot;: {"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;name&quot;: &quot;payee69224601&quot;"/>
  <testsuite tests="0" failures="0" errors="0" name="}"/>
  <testsuite tests="4" failures="0" errors="0" name="}">
    <testcase name="#83 transferId match"/>
    <testcase name="#84 packet match"/>
    <testcase name="#85 condition match"/>
    <testcase name="#86 fulfilment match"/>
  </testsuite>
  <testsuite tests="3" failures="0" errors="0" name="update">
    <testcase name="#87 ilp is updated"/>
    <testcase name="#88 ids match"/>
    <testcase name="#89 update is real"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Transfer Error model test"/>
  <testsuite tests="1" failures="0" errors="0" name="setup">
    <testcase name="#90 setup OK"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="create transfer Error test"/>
  <testsuite tests="3" failures="0" errors="0" name="the prepared data are:">
    <testcase name="#91 transferStateChangeId match"/>
    <testcase name="#92 errorCode match"/>
    <testcase name="#93 errorDescription match"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create transferError without transferStateChangeId should throw error">
    <testcase name="#94 insert into `transferError` (`errorCode`, `errorDescription`, `transferStateChangeId`) values (DEFAULT, DEFAULT, {&quot;transferStateChangeId&quot;:0,&quot;errorCode&quot;:3106,&quot;errorDescription&quot;:&quot;Invalid Request&quot;}) - ER_WRONG_VALUE_COUNT_ON_ROW: Column count doesn't match value count at row 1"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Extension model test"/>
  <testsuite tests="1" failures="0" errors="0" name="setup">
    <testcase name="#95 setup OK"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="create extension"/>
  <testsuite tests="0" failures="0" errors="0" name="Testing with extension"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferId&quot;: &quot;1&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;key&quot;: &quot;extTestKey1&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;value&quot;: &quot;extTestValue1&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:13:45.618Z&quot;"/>
  <testsuite tests="4" failures="0" errors="0" name="}">
    <testcase name="#96 transferId match"/>
    <testcase name="#97 key match"/>
    <testcase name="#98 value match"/>
    <testcase name="#99 createdDate match"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create transferExtension without transferId should throw error">
    <testcase name="#100 insert into `transferExtension` (`createdDate`, `key`, `value`) values ('2018-12-04 19:13:45.932', 'extTestKey1', 'extTestValue1') - ER_NO_DEFAULT_FOR_FIELD: Field 'transferId' doesn't have a default value"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create transferExtension without value should throw error">
    <testcase name="#101 insert into `transferExtension` (`createdDate`, `key`, `transferId`) values ('2018-12-04 19:13:45.934', 'extTestKey1', '31d73e7d-43b9-423f-b07a-67372650f04b') - ER_NO_DEFAULT_FOR_FIELD: Field 'value' doesn't have a default value"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create transferExtension without key should throw error">
    <testcase name="#102 insert into `transferExtension` (`createdDate`, `transferId`, `value`) values ('2018-12-04 19:13:45.937', '31d73e7d-43b9-423f-b07a-67372650f04b', 'extTestValue1') - ER_NO_DEFAULT_FOR_FIELD: Field 'key' doesn't have a default value"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="getByTransferId">
    <testcase name="#103 should be equal"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Testing with extension"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferExtensionId&quot;: 13,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferId&quot;: &quot;31d73e7d-43b9-423f-b07a-67372650f04b&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferFulfilmentId&quot;: null,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;key&quot;: &quot;extension.key&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;value&quot;: &quot;extension.value&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:13:46.000Z&quot;"/>
  <testsuite tests="4" failures="0" errors="0" name="}">
    <testcase name="#104 transferId match"/>
    <testcase name="#105 key match"/>
    <testcase name="#106 value match"/>
    <testcase name="#107 changedDate match"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="getByTransferExtensionId">
    <testcase name="#108 should be equal"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Testing with extension"/>
  <testsuite tests="0" failures="0" errors="0" name="{"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferExtensionId&quot;: 13,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferId&quot;: &quot;31d73e7d-43b9-423f-b07a-67372650f04b&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;transferFulfilmentId&quot;: null,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;key&quot;: &quot;extension.key&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;value&quot;: &quot;extension.value&quot;,"/>
  <testsuite tests="0" failures="0" errors="0" name="&quot;createdDate&quot;: &quot;2018-12-04T19:13:46.000Z&quot;"/>
  <testsuite tests="5" failures="0" errors="0" name="}">
    <testcase name="#109 extensionId match"/>
    <testcase name="#110 transferId match"/>
    <testcase name="#111 key match"/>
    <testcase name="#112 value match"/>
    <testcase name="#113 createdDate match"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="Transfer State Change model test"/>
  <testsuite tests="1" failures="0" errors="0" name="setup">
    <testcase name="#114 setup OK"/>
  </testsuite>
  <testsuite tests="0" failures="0" errors="0" name="create state change test"/>
  <testsuite tests="3" failures="0" errors="0" name="the prepared data is:">
    <testcase name="#115 transferId match"/>
    <testcase name="#116 key match"/>
    <testcase name="#117 value match"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create stateChange without transferId should throw error">
    <testcase name="#118 insert into `transferStateChange` (`createdDate`, `reason`, `transferStateId`) values ('2018-12-04 19:13:46.684', NULL, 'ABORTED') - ER_NO_DEFAULT_FOR_FIELD: Field 'transferId' doesn't have a default value"/>
  </testsuite>
  <testsuite tests="1" failures="0" errors="0" name="create stateChange without transferStateId should throw error">
    <testcase name="#119 insert into `transferStateChange` (`createdDate`, `reason`, `transferId`) values ('2018-12-04 19:13:46.693', NULL, 'a01721a1-a3d7-49d0-ad33-68bd937f65ca') - ER_NO_DEFAULT_FOR_FIELD: Field 'transferStateId' doesn't have a default value"/>
  </testsuite>
</testsuites>

Copy link
Member

@ggrg ggrg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please, don't forget to update the story and link it to this PR, and also thick off the acceptance criteria. PR looks fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants