func BuildBuildCommand() *Command { commandFlags := NewBuildCommandFlags(flag.NewFlagSet("build", flag.ExitOnError)) interruptHandler := interrupthandler.NewInterruptHandler() builder := &SpecBuilder{ commandFlags: commandFlags, interruptHandler: interruptHandler, } return &Command{ Name: "build", FlagSet: commandFlags.FlagSet, UsageCommand: "ginkgo build <FLAGS> <PACKAGES>", Usage: []string{ "Build the passed in <PACKAGES> (or the package in the current directory if left blank).", "Accepts the following flags:", }, Command: builder.BuildSpecs, } }
func BuildRunCommand() *Command { commandFlags := NewRunCommandFlags(flag.NewFlagSet("ginkgo", flag.ExitOnError)) notifier := NewNotifier(commandFlags) interruptHandler := interrupthandler.NewInterruptHandler() runner := &SpecRunner{ commandFlags: commandFlags, notifier: notifier, interruptHandler: interruptHandler, suiteRunner: NewSuiteRunner(notifier, interruptHandler), } return &Command{ Name: "", FlagSet: commandFlags.FlagSet, UsageCommand: "ginkgo <FLAGS> <PACKAGES> -- <PASS-THROUGHS>", Usage: []string{ "Run the tests in the passed in <PACKAGES> (or the package in the current directory if left blank).", "Any arguments after -- will be passed to the test.", "Accepts the following flags:", }, Command: runner.RunSpecs, } }