mirror of
https://github.com/corda/corda.git
synced 2024-12-23 23:02:29 +00:00
Encumbrances implemented by reference to an index of an output state
This commit is contained in:
parent
2c7d6fc053
commit
b4be27080c
@ -14,8 +14,8 @@ import static com.r3corda.core.testing.CoreTestUtils.*;
|
||||
public class CashTestsJava {
|
||||
private final OpaqueBytes defaultRef = new OpaqueBytes(new byte[]{1});
|
||||
private final PartyAndReference defaultIssuer = getMEGA_CORP().ref(defaultRef);
|
||||
private final Cash.State inState = new Cash.State(issuedBy(DOLLARS(1000), defaultIssuer), getDUMMY_PUBKEY_1());
|
||||
private final Cash.State outState = new Cash.State(inState.getAmount(), getDUMMY_PUBKEY_2());
|
||||
private final Cash.State inState = new Cash.State(issuedBy(DOLLARS(1000), defaultIssuer), getDUMMY_PUBKEY_1(), null);
|
||||
private final Cash.State outState = new Cash.State(inState.getAmount(), getDUMMY_PUBKEY_2(), null);
|
||||
|
||||
@Test
|
||||
public void trivial() {
|
||||
@ -25,7 +25,7 @@ public class CashTestsJava {
|
||||
tx.failsWith("the amounts balance");
|
||||
|
||||
tx.tweak(tw -> {
|
||||
tw.output(new Cash.State(issuedBy(DOLLARS(2000), defaultIssuer), getDUMMY_PUBKEY_2()));
|
||||
tw.output(new Cash.State(issuedBy(DOLLARS(2000), defaultIssuer), getDUMMY_PUBKEY_2(), null));
|
||||
return tw.failsWith("the amounts balance");
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user