Documentation ¶
Overview ¶
Package cstesting defines helpers to test Chainscripts.
Index ¶
- func ChangeMapID(l *cs.Link) *cs.Link
- func ChangeState(l *cs.Link) *cs.Link
- func Clone(l *cs.Link) *cs.Link
- func CreateLink(process, mapID, prevLinkHash string, tags []interface{}, priority float64) *cs.Link
- func InvalidLinkWithProcess(process string) *cs.Link
- func RandomBranch(parent *cs.Link) *cs.Link
- func RandomEvidence() *cs.Evidence
- func RandomLink() *cs.Link
- func RandomLinkWithProcess(process string) *cs.Link
- func RandomSegment() *cs.Segment
- func RandomTags() []interface{}
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ChangeMapID ¶ added in v0.2.0
ChangeMapID clones a link and randomly changes its map ID.
func ChangeState ¶ added in v0.2.0
ChangeState clones a link and randomly changes its state.
func CreateLink ¶ added in v0.2.0
CreateLink creates a minimal link.
func InvalidLinkWithProcess ¶ added in v0.2.0
InvalidLinkWithProcess creates a random invalid link.
func RandomBranch ¶
RandomBranch appends a random link to a link.
func RandomEvidence ¶ added in v0.2.0
RandomEvidence creates a random evidence.
func RandomLinkWithProcess ¶ added in v0.2.0
RandomLinkWithProcess creates a random link in a specific process.
func RandomTags ¶
func RandomTags() []interface{}
RandomTags creates between zero and four random tags.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.