testhelpers

package
v0.1.36 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 26, 2022 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertConfig

func AssertConfig(t *testing.T, configDir string, email string, name string, newsletter bool)

func ChangeAccessToken

func ChangeAccessToken(t require.TestingT, configDir string)

func ClearConfig

func ClearConfig(t require.TestingT, configDir string)

func ConfigAwareCmd

func ConfigAwareCmd(configDir string) *cmdx.CommandExecuter

func ConfigPasswordAwareCmd

func ConfigPasswordAwareCmd(configDir, password string) *cmdx.CommandExecuter

func CreateDefaultAssets

func CreateDefaultAssets() (defaultConfig, defaultEmail, defaultPassword, defaultProject string, defaultCmd *cmdx.CommandExecuter)

func CreateProject

func CreateProject(t require.TestingT, configDir string) string

func FakeEmail

func FakeEmail() string

func FakeName

func FakeName() string

func FakePassword

func FakePassword() string

func ImportIdentity

func ImportIdentity(t require.TestingT, cmd *cmdx.CommandExecuter, project string, stdin *bytes.Buffer) string

func MakeRandomIdentity

func MakeRandomIdentity(t require.TestingT, email string) string

func NewConfigDir

func NewConfigDir(t require.TestingT) string

func ReadConfig

func ReadConfig(t require.TestingT, configDir string) *client.AuthContext

func RegisterAccount

func RegisterAccount(t require.TestingT, configDir string) (email, password string)

func RunAgainstStaging

func RunAgainstStaging(m *testing.M)

func TestProjectName

func TestProjectName() string

func UseStaging

func UseStaging()

func WithReAuth

func WithReAuth(t require.TestingT, email, password string) (*cmdx.CommandExecuter, *bytes.Buffer)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL