Documentation ¶
Index ¶
- Variables
- func ConfigureDuo(t *testing.T, allowDeny DuoPolicy)
- func ConfigureDuoPreAuth(t *testing.T, response duo.PreAuthResponse)
- func GetLoginBaseURL() string
- func NewHTTPClient() *http.Client
- type CommandSuite
- type DockerEnvironment
- func (de *DockerEnvironment) Down() error
- func (de *DockerEnvironment) Exec(service string, command []string) (string, error)
- func (de *DockerEnvironment) Logs(service string, flags []string) (string, error)
- func (de *DockerEnvironment) Pull(images ...string) error
- func (de *DockerEnvironment) Restart(service string) error
- func (de *DockerEnvironment) Start(service string) error
- func (de *DockerEnvironment) Stop(service string) error
- func (de *DockerEnvironment) Up() error
- type DuoPolicy
- type Kind
- type Kubectl
- type Registry
- type RodSession
- func (rs *RodSession) Stop() error
- func (rs *RodSession) WaitElementLocatedByClassName(t *testing.T, page *rod.Page, className string) *rod.Element
- func (rs *RodSession) WaitElementLocatedByID(t *testing.T, page *rod.Page, cssSelector string) *rod.Element
- func (rs *RodSession) WaitElementsLocatedByID(t *testing.T, page *rod.Page, cssSelector string) rod.Elements
- type RodSuite
- type Suite
Constants ¶
This section is empty.
Variables ¶
var AdminBaseURL = fmt.Sprintf("https://admin.%s", BaseDomain)
AdminBaseURL the base URL of the admin domain.
var AutheliaBaseURL = "https://authelia.example.com:9091"
AutheliaBaseURL the base URL of Authelia service.
var BaseDomain = "example.com:8080"
BaseDomain the base domain.
var DevBaseURL = fmt.Sprintf("https://dev.%s", BaseDomain)
DevBaseURL the base URL of the dev domain.
var DuoBaseURL = "https://duo.example.com"
DuoBaseURL the base URL of the Duo configuration API.
var HomeBaseURL = fmt.Sprintf("https://home.%s", BaseDomain)
HomeBaseURL the base URL of the home domain.
var LoginBaseURL = fmt.Sprintf("https://login.%s", BaseDomain)
LoginBaseURL the base URL of the login portal.
var MX1MailBaseURL = fmt.Sprintf("https://mx1.mail.%s", BaseDomain)
MX1MailBaseURL the base URL of the mx1.mail domain.
var MX2MailBaseURL = fmt.Sprintf("https://mx2.mail.%s", BaseDomain)
MX2MailBaseURL the base URL of the mx2.mail domain.
var MailBaseURL = fmt.Sprintf("https://mail.%s", BaseDomain)
MailBaseURL the base URL of the mail domain.
var OIDCBaseURL = fmt.Sprintf("https://oidc.%s", BaseDomain)
OIDCBaseURL the base URL of the oidc domain.
var PathPrefix = os.Getenv("PathPrefix")
PathPrefix the prefix/url_base of the login portal.
var PublicBaseURL = fmt.Sprintf("https://public.%s", BaseDomain)
PublicBaseURL the base URL of the public domain.
var SecureBaseURL = fmt.Sprintf("https://secure.%s", BaseDomain)
SecureBaseURL the base URL of the secure domain.
var SingleFactorBaseURL = fmt.Sprintf("https://singlefactor.%s", BaseDomain)
SingleFactorBaseURL the base URL of the singlefactor domain.
Functions ¶
func ConfigureDuo ¶
ConfigureDuo configure duo api to allow or block auth requests.
func ConfigureDuoPreAuth ¶ added in v4.33.0
func ConfigureDuoPreAuth(t *testing.T, response duo.PreAuthResponse)
ConfigureDuoPreAuth configure duo api to respond with available devices or enrollment Url.
func GetLoginBaseURL ¶
func GetLoginBaseURL() string
GetLoginBaseURL returns the URL of the login portal and the path prefix if specified.
func NewHTTPClient ¶
NewHTTPClient create a new client skipping TLS verification and not redirecting.
Types ¶
type CommandSuite ¶
type CommandSuite struct { suite.Suite *DockerEnvironment // contains filtered or unexported fields }
CommandSuite is a command line interface suite.
type DockerEnvironment ¶
type DockerEnvironment struct {
// contains filtered or unexported fields
}
DockerEnvironment represent a docker environment.
func NewDockerEnvironment ¶
func NewDockerEnvironment(files []string) *DockerEnvironment
NewDockerEnvironment create a new docker environment.
func (*DockerEnvironment) Down ¶
func (de *DockerEnvironment) Down() error
Down destroy a docker environment.
func (*DockerEnvironment) Exec ¶
func (de *DockerEnvironment) Exec(service string, command []string) (string, error)
Exec execute a command within a given service of the environment.
func (*DockerEnvironment) Logs ¶
func (de *DockerEnvironment) Logs(service string, flags []string) (string, error)
Logs get logs of a given service of the environment.
func (*DockerEnvironment) Pull ¶
func (de *DockerEnvironment) Pull(images ...string) error
Pull pull all images of needed in the environment.
func (*DockerEnvironment) Restart ¶
func (de *DockerEnvironment) Restart(service string) error
Restart restarts a service.
func (*DockerEnvironment) Start ¶
func (de *DockerEnvironment) Start(service string) error
Start a docker service.
func (*DockerEnvironment) Stop ¶
func (de *DockerEnvironment) Stop(service string) error
Stop a docker service.
func (*DockerEnvironment) Up ¶
func (de *DockerEnvironment) Up() error
Up spawn a docker environment.
type Kind ¶
type Kind struct{}
Kind used for running kind commands.
func (Kind) ClusterExists ¶
ClusterExists check whether a cluster exists.
func (Kind) CreateCluster ¶
CreateCluster create a new Kubernetes cluster.
func (Kind) DeleteCluster ¶
DeleteCluster delete a Kubernetes cluster.
type Kubectl ¶
type Kubectl struct{}
Kubectl used for running kubectl commands.
func (Kubectl) DeployAuthelia ¶
DeployAuthelia deploy Authelia application.
func (Kubectl) DeployThirdparties ¶
DeployThirdparties deploy thirdparty services (ldap, db, ingress controllers, etc...).
func (Kubectl) StartDashboard ¶
StartDashboard start Kube dashboard.
func (Kubectl) StopDashboard ¶
StopDashboard stop kube dashboard.
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry represent a registry of suite by name.
var GlobalRegistry *Registry
GlobalRegistry a global registry used by Authelia tooling.
func NewSuitesRegistry ¶
func NewSuitesRegistry() *Registry
NewSuitesRegistry create a suites registry.
type RodSession ¶ added in v4.33.0
RodSession binding a chrome session with devtool protocol.
func StartRod ¶ added in v4.33.0
func StartRod() (*RodSession, error)
StartRod create a rod/chromedp session.
func StartRodWithProxy ¶ added in v4.33.0
func StartRodWithProxy(proxy string) (*RodSession, error)
StartRodWithProxy create a rod/chromedp session.
func (*RodSession) Stop ¶ added in v4.33.0
func (rs *RodSession) Stop() error
Stop stop the rod/chromedp session.
func (*RodSession) WaitElementLocatedByClassName ¶ added in v4.33.0
func (rs *RodSession) WaitElementLocatedByClassName(t *testing.T, page *rod.Page, className string) *rod.Element
WaitElementLocatedByClassName wait an element is located by class name.
func (*RodSession) WaitElementLocatedByID ¶ added in v4.35.0
func (rs *RodSession) WaitElementLocatedByID(t *testing.T, page *rod.Page, cssSelector string) *rod.Element
WaitElementLocatedByID waits for an element located by an id.
func (*RodSession) WaitElementsLocatedByID ¶ added in v4.35.0
func (rs *RodSession) WaitElementsLocatedByID(t *testing.T, page *rod.Page, cssSelector string) rod.Elements
WaitElementsLocatedByID waits for an elements located by an id.
type RodSuite ¶ added in v4.33.0
type RodSuite struct { suite.Suite *RodSession *rod.Page }
RodSuite is a go-rod suite.
type Suite ¶
type Suite struct { SetUp func(tmpPath string) error SetUpTimeout time.Duration // Callback called when an error occur during setup phase. OnSetupTimeout func() error // Callback called when at least one test fail. OnError func() error TestTimeout time.Duration TearDown func(tmpPath string) error TearDownTimeout time.Duration // A textual description of the suite purpose. Description string }
Suite the definition of a suite.
Source Files ¶
- action_2fa_methods.go
- action_http.go
- action_login.go
- action_logout.go
- action_mail.go
- action_register.go
- action_reset_password.go
- action_totp.go
- action_visit.go
- const.go
- docker.go
- duo.go
- environment.go
- http.go
- kubernetes.go
- registry.go
- suite_activedirectory.go
- suite_bypass_all.go
- suite_cli.go
- suite_docker.go
- suite_duo_push.go
- suite_haproxy.go
- suite_high_availability.go
- suite_kubernetes.go
- suite_ldap.go
- suite_mariadb.go
- suite_mysql.go
- suite_network_acl.go
- suite_oidc.go
- suite_oidc_traefik.go
- suite_one_factor_only.go
- suite_pathprefix.go
- suite_postgres.go
- suite_short_timeouts.go
- suite_standalone.go
- suite_traefik.go
- suite_traefik2.go
- suites.go
- utils.go
- verify_body_contains.go
- verify_is_authenticated_page.go
- verify_is_consent_page.go
- verify_is_first_factor_page.go
- verify_is_home.go
- verify_is_oidc.go
- verify_is_public.go
- verify_is_second_factor_page.go
- verify_mail.go
- verify_notification.go
- verify_secret_authorized.go
- verify_url_is.go
- webdriver.go