Documentation
¶
Index ¶
- func AssertCommandSucceeds(t *testing.T, err error, cmdDesc string)
- func AssertDirExists(t *testing.T, p *Project, path string)
- func AssertFileContains(t *testing.T, p *Project, path, expected string)
- func AssertFileExists(t *testing.T, p *Project, path string)
- func AssertFilesExist(t *testing.T, p *Project, paths []string)
- func AssertGoVetPasses(t *testing.T, p *Project)
- func AssertOutputContains(t *testing.T, output, expected string)
- func RunCLI(t *testing.T, binary, workDir string, env []string, args ...string) error
- func RunCommand(t *testing.T, cmdName, workDir string, env []string, args ...string) error
- func RunCommandExpectError(t *testing.T, cmdName, workDir string, env []string, args ...string) error
- func RunCommandOutput(t *testing.T, cmdName, workDir string, env []string, args ...string) (string, error)
- type Project
- func (p *Project) DirExists(path string) bool
- func (p *Project) FileExists(path string) bool
- func (p *Project) Generate(args ...string) error
- func (p *Project) GenerateExpectError(args ...string) error
- func (p *Project) GoBuild(target string) error
- func (p *Project) GoVet() error
- func (p *Project) Scaffold(args ...string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertCommandSucceeds ¶
AssertCommandSucceeds performs assert command succeeds.
func AssertDirExists ¶
AssertDirExists performs assert dir exists.
func AssertFileContains ¶ added in v1.0.0
AssertFileContains performs assert file contains.
func AssertFileExists ¶
AssertFileExists performs assert file exists.
func AssertFilesExist ¶
AssertFilesExist performs assert files exist.
func AssertGoVetPasses ¶
AssertGoVetPasses performs assert go vet passes.
func AssertOutputContains ¶
AssertOutputContains performs assert output contains.
func RunCommand ¶
RunCommand runs command.
Types ¶
type Project ¶
type Project struct {
Dir string
Name string
T *testing.T
BinaryPath string
Database string
CSS string
}
Project represents project.
func NewProject ¶
NewProject creates a new project.
func NewProjectWithDatabase ¶
NewProjectWithDatabase creates a new project with database.
func (*Project) FileExists ¶
FileExists performs the file exists operation.
func (*Project) GenerateExpectError ¶ added in v1.0.0
GenerateExpectError runs a generate command that is expected to fail, suppressing failure logs.
Click to show internal directories.
Click to hide internal directories.