Skip to content

rajkbess/buggy-cordapp

Repository files navigation

Corda

Buggy CorDapp

The Example CorDapp. Except... no-one wrote any tests and two bugs have slipped through. One in the contract, and one in the flow. You need to write tests to identify these bugs.

Here are the constraints we expect the IOU contract to impose:

  • The transaction has a single command of type IOUContract.Commands.Create
  • The transaction has zero inputs
  • The transaction has one output of type IOUState
  • In the IOUState output:
    • The lender and the borrower are not the same party
    • The iouValue is positive

And here's what we expect the IOU flow to do:

  • Take two arguments, iouValue and otherParty
  • Create a transaction with no inputs and one output, a new IOUState with:
    • A value of iouValue
    • The initiator of the flow as the lender
    • otherParty as the borrower
  • Get both parties to sign the transaction
  • Store the new IOUState in both parties' vaults

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages