Project: quorum-acceptance-tests

Failed: 2/6 Passed: 4/6 Skipped: 0/6
6Total specs
  • 2Failed
  • 4Passed
  • default
  • 66%
  • 00:01:13
  • Oct 1, 2018 at 2:22pm

State manipulation in private smart contract

00:00:03

A simple smart contract is to store a int value and to provide get() and set() functions. Non-participated party from original transaction is trying to modify the private state of the participated party.

Private state is maintained

00:00:03
Tags: privacy state
Execution Time : 00:00:01
  • Deploy a simple smart contract with initial value "100" in "Node1" 's default account and it's private for "Node7" , named this contract as "contract17" .
Execution Time : 00:00:02
  • Execute "contract17" 's `set()` function with new value "0" in "Node3" and it's private for "Node1" .
Execution Time : 00:00:00
  • "contract17" 's `get()` function execution in "Node1" returns "100" .

    org.junit.ComparisonFailure: expected:<[10]0> but was:<[]0>

    sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    com.quorum.gauge.PrivateSmartContract.verifyPrivacyWithParticipatedNodes(PrivateSmartContract.java:88)