Testing Triggers: `testRule` : Auto-build ACS instead of manually building it?
- StephenOTTOP
From the examples to test a trigger, you use the
testRulefunction. This function takes a ACSBuilder which is manually built from the objects provided. is there a function / way to auto-build the acs based on previous actions take in a test?In a test, if i ran:
objA <- submit alice do createCmd Object1 with user1 = alice objB <- submit alice do createCmd Object1 with user1 = alice objC <- submit alice do createCmd Object1 with user1 = aliceIt would generate 3 contracts in the ACS / ledger / test context. I could then run the testRule and say “use the current ACS from this test context”.
Is this possible?
- cocreature
Currently this is not possible. There is an open feature request for this though.
- StephenOTT
Thanks