Documentation ¶
Index ¶
- type Aliases
- type BodyContent
- type BodyTemplate
- type Command
- func (c *Command) GetAllParameters() []Parameter
- func (c *Command) GetBodyContentType() string
- func (c *Command) GetDescriptionLong() string
- func (c *Command) GetExamples() string
- func (c *Command) GetMethod() string
- func (c *Command) GetQueryParameters() []Parameter
- func (c *Command) HasPreset() bool
- func (c *Command) IsBodyFormData() bool
- func (c *Command) IsCollection() bool
- func (c *Command) IsDeprecated() bool
- func (c *Command) IsHidden() bool
- func (c *Command) ShouldIgnore() bool
- func (c *Command) SupportsProcessingMode() bool
- func (c *Command) SupportsTemplates() bool
- type CommandPreset
- type Completion
- type Configuration
- type Example
- type Examples
- type Group
- type MockConfiguration
- type NamedLookup
- type NamedLookupOptions
- type OutputAssertion
- type Parameter
- func (p *Parameter) AcceptsPipeline() bool
- func (p *Parameter) GetDependentProperty(index int, defaultValue string) string
- func (p *Parameter) GetDescription() string
- func (p *Parameter) GetTargetProperty() string
- func (p *Parameter) IsHidden() bool
- func (p *Parameter) IsRequired() bool
- func (p *Parameter) IsTypeDateTime() bool
- type Specification
- type TargetType
- type TestCase
- type TestSuite
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BodyContent ¶
type BodyContent struct {
Type string `yaml:"type,omitempty"`
}
type BodyTemplate ¶ added in v2.30.0
type Command ¶ added in v2.30.0
type Command struct { Name string `yaml:"name"` Description string `yaml:"description"` DescriptionLong string `yaml:"descriptionLong"` Preset CommandPreset `yaml:"preset"` Deprecated string `yaml:"deprecated"` DeprecatedAt string `yaml:"deprecatedAt"` Method string `yaml:"method"` SemanticMethod string `yaml:"semanticMethod"` Accept string `yaml:"accept,omitempty"` ContentType string `yaml:"contentType,omitempty"` CollectionType string `yaml:"collectionType,omitempty"` CollectionProperty string `yaml:"collectionProperty,omitempty"` Path string `yaml:"path"` Examples Examples `yaml:"examples"` ExampleList []Example `yaml:"exampleList"` Alias Aliases `yaml:"alias"` Hidden *bool `yaml:"hidden,omitempty"` Skip *bool `yaml:"skip,omitempty"` QueryParameters []Parameter `yaml:"queryParameters,omitempty"` PathParameters []Parameter `yaml:"pathParameters,omitempty"` HeaderParameters []Parameter `yaml:"headerParameters,omitempty"` Body []Parameter `yaml:"body,omitempty"` BodyContent *BodyContent `yaml:"bodyContent,omitempty"` BodyTemplates []BodyTemplate `yaml:"bodyTemplates,omitempty"` BodyRequiredKeys []string `yaml:"bodyRequiredKeys,omitempty"` FlagMapping map[string]string `yaml:"flagMapping"` }
func (*Command) GetAllParameters ¶ added in v2.30.0
func (*Command) GetBodyContentType ¶ added in v2.30.0
func (*Command) GetDescriptionLong ¶ added in v2.30.0
func (*Command) GetExamples ¶ added in v2.30.0
func (*Command) GetQueryParameters ¶ added in v2.30.0
func (*Command) IsBodyFormData ¶ added in v2.30.0
func (*Command) IsCollection ¶ added in v2.30.0
func (*Command) IsDeprecated ¶ added in v2.30.0
func (*Command) ShouldIgnore ¶ added in v2.30.0
func (*Command) SupportsProcessingMode ¶ added in v2.30.0
func (*Command) SupportsTemplates ¶ added in v2.30.0
type CommandPreset ¶ added in v2.30.0
type Completion ¶ added in v2.30.0
type Configuration ¶
type Example ¶
type Example struct { Description string `yaml:"description,omitempty"` Command string `yaml:"command"` AssertStdout *OutputAssertion `yaml:"assertStdOut,omitempty"` AssertStderr *OutputAssertion `yaml:"assertStdErr,omitempty"` BeforeEach []string `yaml:"beforeEach,omitempty"` AfterEach []string `yaml:"afterEach,omitempty"` SkipTest bool `yaml:"skipTest,omitempty"` }
type MockConfiguration ¶
type MockConfiguration struct { Mocks map[string]string `yaml:"mocks,omitempty"` Files map[string]string `yaml:"files,omitempty"` }
func (*MockConfiguration) Replace ¶
func (c *MockConfiguration) Replace(command string) string
func (*MockConfiguration) ReplaceFiles ¶
func (c *MockConfiguration) ReplaceFiles(command string) string
type NamedLookup ¶ added in v2.30.0
type NamedLookup struct { Type string `yaml:"type,omitempty"` Command []string `yaml:"command,omitempty"` Options NamedLookupOptions `yaml:"options"` }
type NamedLookupOptions ¶ added in v2.30.0
type NamedLookupOptions struct {
IDPattern string `yaml:"idPattern,omitempty"`
}
type OutputAssertion ¶
type Parameter ¶
type Parameter struct { Name string `yaml:"name,omitempty"` ShortName string `yaml:"shortname,omitempty"` Type string `yaml:"type,omitempty"` Value string `yaml:"value,omitempty"` Completion Completion `yaml:"completion,omitempty"` NamedLookup NamedLookup `yaml:"lookup,omitempty"` Format string `yaml:"format,omitempty"` Property string `yaml:"property,omitempty"` Hidden *bool `yaml:"hidden,omitempty"` Pipeline *bool `yaml:"pipeline,omitempty"` PipelineAliases []string `yaml:"pipelineAliases,omitempty"` Required *bool `yaml:"required,omitempty"` Description string `yaml:"description,omitempty"` Default string `yaml:"default,omitempty"` Position *int `yaml:"position,omitempty"` ValidationSet []string `yaml:"validationSet,omitempty"` Skip *bool `yaml:"skip,omitempty"` Children []Parameter `yaml:"children,omitempty"` DependsOn []string `yaml:"dependsOn,omitempty"` TargetType TargetType `yaml:"-"` }
func (*Parameter) AcceptsPipeline ¶ added in v2.30.0
func (*Parameter) GetDependentProperty ¶ added in v2.30.0
Get the first dependent property name defined for the current parameter. Return a default value if no dependent property is defined
func (*Parameter) GetDescription ¶ added in v2.30.0
func (*Parameter) GetTargetProperty ¶
func (*Parameter) IsRequired ¶ added in v2.30.0
func (*Parameter) IsTypeDateTime ¶
type Specification ¶
type TargetType ¶ added in v2.30.0
type TargetType int
const ( ParamHeader TargetType = iota ParamBody ParamPath ParamQueryParameter )
type TestCase ¶
type TestCase struct { Command string `yaml:"command,omitempty"` ExitCode int `yaml:"exit-code"` Skip bool `yaml:"skip,omitempty"` LineCount int `yaml:"line-count,omitempty"` StdOut *OutputAssertion `yaml:"stdout,omitempty"` StdErr *OutputAssertion `yaml:"stderr,omitempty"` Configuration *Configuration `yaml:"config,omitempty"` }
type TestSuite ¶
type TestSuite struct { Configuration *Configuration `yaml:"config,omitempty"` Tests map[string]TestCase `yaml:"tests"` }
Click to show internal directories.
Click to hide internal directories.