cf-test-helpers: github.com/simonleung8/cf-test-helpers/helpers Index | Files

package helpers

import "github.com/simonleung8/cf-test-helpers/helpers"

Index

Package Files

app_commands.go artifacts.go config.go context.go environment.go

Constants

const CF_API_TIMEOUT = 30 * time.Second
const CURL_TIMEOUT = 10 * time.Second

func AppRootUri Uses

func AppRootUri(appName string) string

Gets an app's root endpoint

func AppUri Uses

func AppUri(appName, path string) string

Gets an app's endpoint with the specified path

func CurlApp Uses

func CurlApp(appName, path string) string

Curls an app's endpoint and exit successfully before the default timeout

func CurlAppRoot Uses

func CurlAppRoot(appName string) string

Curls an app's root endpoint and exit successfully before the default timeout

func CurlAppWithTimeout Uses

func CurlAppWithTimeout(appName, path string, timeout time.Duration) string

Curls an app's endpoint and exit successfully before the specified timeout

func CurlingAppRoot Uses

func CurlingAppRoot(appName string) func() string

Returns a function that curls an app's root endpoint and exit successfully before the default timeout

func EnableCFTrace Uses

func EnableCFTrace(config Config, componentName string)

func NewJUnitReporter Uses

func NewJUnitReporter(config Config, componentName string) *reporters.JUnitReporter

type Config Uses

type Config struct {
    ApiEndpoint string `json:"api"`
    AppsDomain  string `json:"apps_domain"`

    AdminUser     string `json:"admin_user"`
    AdminPassword string `json:"admin_password"`

    PersistentAppHost      string `json:"persistent_app_host"`
    PersistentAppSpace     string `json:"persistent_app_space"`
    PersistentAppOrg       string `json:"persistent_app_org"`
    PersistentAppQuotaName string `json:"persistent_app_quota_name"`

    SkipSSLValidation bool `json:"skip_ssl_validation"`

    ArtifactsDirectory string `json:"artifacts_directory"`
}

func LoadConfig Uses

func LoadConfig() Config

type ConfiguredContext Uses

type ConfiguredContext struct {
    // contains filtered or unexported fields
}

func NewContext Uses

func NewContext(config Config) *ConfiguredContext

func NewPersistentAppContext Uses

func NewPersistentAppContext(config Config) *ConfiguredContext

func (*ConfiguredContext) AdminUserContext Uses

func (context *ConfiguredContext) AdminUserContext() cf.UserContext

func (*ConfiguredContext) RegularUserContext Uses

func (context *ConfiguredContext) RegularUserContext() cf.UserContext

func (*ConfiguredContext) Setup Uses

func (context *ConfiguredContext) Setup()

func (*ConfiguredContext) Teardown Uses

func (context *ConfiguredContext) Teardown()

type Environment Uses

type Environment struct {
    // contains filtered or unexported fields
}

func NewEnvironment Uses

func NewEnvironment(context SuiteContext) *Environment

func (*Environment) Setup Uses

func (e *Environment) Setup()

func (*Environment) Teardown Uses

func (e *Environment) Teardown()

type SuiteContext Uses

type SuiteContext interface {
    Setup()
    Teardown()

    AdminUserContext() cf.UserContext
    RegularUserContext() cf.UserContext
}

Package helpers imports 12 packages (graph). Updated 2017-05-11. Refresh now. Tools for package owners.