tests

package
v1.6.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 11, 2017 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Overview

Package tests implements execution of Ethereum JSON tests.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlockTest

type BlockTest struct {
	// contains filtered or unexported fields
}

A BlockTest checks handling of entire blocks.

func (*BlockTest) Run added in v1.6.7

func (t *BlockTest) Run(config *params.ChainConfig) error

func (*BlockTest) UnmarshalJSON added in v1.6.7

func (t *BlockTest) UnmarshalJSON(in []byte) error

type RLPTest

type RLPTest struct {
	// If the value of In is "INVALID" or "VALID", the test
	// checks whether Out can be decoded into a value of
	// type interface{}.
	//
	// For other JSON values, In is treated as a driver for
	// calls to rlp.Stream. The test also verifies that encoding
	// In produces the bytes in Out.
	In interface{}

	// Out is a hex-encoded RLP value.
	Out string
}

RLPTest is the JSON structure of a single RLP test.

func (*RLPTest) Run

func (t *RLPTest) Run() error

Run executes the test.

type StateSubtest added in v1.6.7

type StateSubtest struct {
	Fork  string
	Index int
}

StateSubtest selects a specific configuration of a General State Test.

type StateTest added in v1.6.7

type StateTest struct {
	// contains filtered or unexported fields
}

StateTest checks transaction processing without block context. See https://github.com/ethereum/EIPs/issues/176 for the test format specification.

func (*StateTest) Run added in v1.6.7

func (t *StateTest) Run(subtest StateSubtest, vmconfig vm.Config) error

Run executes a specific subtest.

func (*StateTest) Subtests added in v1.6.7

func (t *StateTest) Subtests() []StateSubtest

Subtests returns all valid subtests of the test.

func (*StateTest) UnmarshalJSON added in v1.6.7

func (t *StateTest) UnmarshalJSON(in []byte) error

type TransactionTest

type TransactionTest struct {
	// contains filtered or unexported fields
}

TransactionTest checks RLP decoding and sender derivation of transactions.

func (*TransactionTest) Run added in v1.6.7

func (tt *TransactionTest) Run(config *params.ChainConfig) error

type VMTest added in v1.6.7

type VMTest struct {
	// contains filtered or unexported fields
}

VMTest checks EVM execution without block or transaction context. See https://github.com/ethereum/tests/wiki/VM-Tests for the test format specification.

func (*VMTest) Run added in v1.6.7

func (t *VMTest) Run(vmconfig vm.Config) error

func (*VMTest) UnmarshalJSON added in v1.6.7

func (t *VMTest) UnmarshalJSON(data []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL