Documentation
¶
Index ¶
- func RunCli(args ...string) (string, error)
- func RunCliWithStdin(stdin string, args ...string) (string, error)
- type Actions
- type Consequences
- func (c *Consequences) And(block func()) *Consequences
- func (c *Consequences) AndCLIOutput(block func(output string, err error)) *Consequences
- func (c *Consequences) AndExportedResources(block func(resources *utils.ExportedResources, err error))
- func (c *Consequences) Given() *Context
- func (c *Consequences) When() *Actions
- type Context
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Actions ¶
type Actions struct {
// contains filtered or unexported fields
}
this implements the "when" part of given/when/then
none of the func implement error checks, and that is complete intended, you should check for errors using the Then()
func (*Actions) Then ¶
func (a *Actions) Then() *Consequences
type Consequences ¶
type Consequences struct {
// contains filtered or unexported fields
}
this implements the "then" part of given/when/then
func (*Consequences) And ¶
func (c *Consequences) And(block func()) *Consequences
func (*Consequences) AndCLIOutput ¶
func (c *Consequences) AndCLIOutput(block func(output string, err error)) *Consequences
func (*Consequences) AndExportedResources ¶
func (c *Consequences) AndExportedResources(block func(resources *utils.ExportedResources, err error))
For use after running export with the exported resources desirialized
func (*Consequences) Given ¶
func (c *Consequences) Given() *Context
func (*Consequences) When ¶
func (c *Consequences) When() *Actions
type Context ¶
Context implements the "given" part of given/when/then. It embeds fixture.TestState to provide test-specific state that enables parallel test execution.
func GivenWithSameState ¶
func GivenWithSameState(ctx fixture.TestContext) *Context
GivenWithSameState creates a new Context that shares the same TestState as an existing context. Use this when you need multiple fixture contexts within the same test.
Click to show internal directories.
Click to hide internal directories.