Commit Graph

15 Commits

Author SHA1 Message Date
Anton Evangelatov
ffe3019561
messages/nested suite (#215)
* wip

* print out failing test

* missing account in state

* enable puppet test

* add missing preroot

* add puppet actor to lvm

* refactor getting post root and serialize of test vector (#217)
2020-08-10 16:38:34 +02:00
Alan Shaw
47f0ef0eae
test: port chain validation multisig test suite (#216) 2020-08-07 16:45:52 +01:00
Alan Shaw
be5bd41640
feat: add test name to test vector meta (#214)
So we can more easily distinguish between test vectors.
2020-08-07 15:36:00 +01:00
Anton Evangelatov
de62012a7f
add messages/transfer suite (#213) 2020-08-07 16:25:58 +02:00
Alan Shaw
a793824d2c
feat: test driver automatically records applied messages in test vector (#212)
The `TestDriver` now records applied messages in it's `TestVector` whenever an `Apply*` method is called. This removes the need for manual message serialization and recording in the tests.
2020-08-07 15:12:38 +01:00
Alan Shaw
52cf367a92
feat: add MustMarshalJSON for more DRY outputting (#211)
Small change to make encoding and printing the test vector output a bit more succinct.
2020-08-07 14:09:10 +01:00
Alan Shaw
81ea0ec5f3
refactor: add default TestVector to TestDriver (#208)
This PR adds a `TestVector` to the `TestDriver` so that test driver methods that apply messages can be recorded in the test vector.

refs #194
2020-08-07 13:47:16 +01:00
Anton Evangelatov
7d118e1b12
fix two disabled tests (#207) 2020-08-06 18:57:15 +02:00
Raúl Kripalani
fd35438a30
schema: add message receipts + description and comments informational fields (#209) 2020-08-06 17:20:17 +01:00
Raúl Kripalani
8203a5d2c3
various fixes: warn on predicted nonce mismatch, randomness length, add missing mocked verification calls (#199)
* warn when extracting a message from a tipset that contains
  more leading messages from the same sender, as this leads to
  nonce misalignment.
* fix mocked randomness being too short (must be 32 bytes).
* mock some further verification syscalls.
2020-08-06 10:43:10 +01:00
Anton Evangelatov
9c8ced1fc6
input from stdin functionality for exec-lotus ; initial test suites in ci (#196) 2020-08-05 20:59:57 +02:00
Anton Evangelatov
5353210814
generate test-vectors based on tests from chain-validation project (#181)
* Read a subset of filecoin state over the full node API

* wip

* import export wip

* extract actors from message

* generate car for any state

* library for providing a pruned statetree

* test vector schema draft + example 'message' class test vector.

* message => messages test vector class.

* fixup

* wip

* use lb.NewBlockstore with ID

* fixup lotus-soup, and generate

* fix deals

* magic params

* work on schema / export of test vector

* fixup

* wip deserialise state tree

* pass at building a test case from a message

* progress loading / serializing

* recreation of ipld nodes

* generation of vector creates json

* kick off tvx tool.

* wip

* wip

* retain init actor state.

* initial test with printed out state

* remove testing.T, but keep require and assert libraries

* wip refactor state tree plucking.

* simplified

* removed factories

* remove builder.Build ; remove interface - use concrete iface

* comment out validateState

* remove Validator

* remove TestDriverBuilder

* remove client

* remove box

* remove gen

* remove factories

* remove KeyManager interfafce

* moved stuff around

* remove ValidationConfig

* extract randomness

* extract config and key_manager

* extract statewrapper

* extract applier

* rename factories to various

* flatten chain-validation package

* initial marshal of test vector

* do not require schema package

* fixup

* run all messages tests

* better names

* run all messages tests

* remove Indent setting from JSON encoder for now

* refactor, and actually running successfully ;-)

* remove irrelevant files; rename extract-msg command.

* remove root CID from state_tree object in schema.

* add tvx/lotus package; adjust .gitignore.

* tidy up command flag management.

* add comment.

* remove validateState and trackState

* remove xerrors

* remove NewVM

* remove commented out RootCID sets

* enable more tests

* add all `message_application` tests

* delete all.json

* update Message struct

* fix message serialization

* support multiple messages

* gofmt

* remove custom Message and SignedMessage types

* update tests with gzip and adhere to new schema for compressed CAR

* improved iface for Marshal

* update Validation

* remove test-suites and utils

* better names for chain. methods

* go mod tidy

* remove top-level dummyT

Co-authored-by: Will Scott <will@cypherpunk.email>
Co-authored-by: Raúl Kripalani <raul@protocol.ai>
2020-08-05 19:40:09 +02:00
Anton Evangelatov
17f0b4a2e1
support multiple messages /1 (#185)
* support multiple messages

* update corpus/schema.json

* fix required
2020-08-05 17:00:14 +02:00
Raúl Kripalani
163721651a
dedup state tree CARs from test vectors. (#187) 2020-08-05 15:52:57 +01:00
Raúl Kripalani
b7e3b4ff77
unified tvx tool; end-to-end MVP for extracting+running msg-class vectors (#177)
Co-authored-by: Will Scott <will@cypherpunk.email>
Co-authored-by: Anton Evangelatov <anton.evangelatov@gmail.com>
2020-08-05 13:20:13 +01:00