fix: do not run LDAP tests locally by default
Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>
This commit is contained in:
parent
0f68fadb9a
commit
1f2771b57e
1
.github/workflows/ci.yaml
vendored
1
.github/workflows/ci.yaml
vendored
@ -71,6 +71,7 @@ jobs:
|
|||||||
DEX_POSTGRES_HOST: localhost
|
DEX_POSTGRES_HOST: localhost
|
||||||
DEX_POSTGRES_PORT: ${{ job.services.postgres.ports[5432] }}
|
DEX_POSTGRES_PORT: ${{ job.services.postgres.ports[5432] }}
|
||||||
DEX_ETCD_ENDPOINTS: http://localhost:${{ job.services.etcd.ports[2379] }}
|
DEX_ETCD_ENDPOINTS: http://localhost:${{ job.services.etcd.ports[2379] }}
|
||||||
|
DEX_LDAP_TESTS: yes
|
||||||
DEX_LDAP_HOST: localhost
|
DEX_LDAP_HOST: localhost
|
||||||
DEX_LDAP_PORT: 389
|
DEX_LDAP_PORT: 389
|
||||||
DEX_LDAP_TLS_PORT: 636
|
DEX_LDAP_TLS_PORT: 636
|
||||||
|
@ -526,6 +526,10 @@ func getenv(key, defaultVal string) string {
|
|||||||
// The tests require LDAP to be runnning.
|
// The tests require LDAP to be runnning.
|
||||||
// You can use the provided docker-compose file to setup an LDAP server.
|
// You can use the provided docker-compose file to setup an LDAP server.
|
||||||
func runTests(t *testing.T, connMethod connectionMethod, config *Config, tests []subtest) {
|
func runTests(t *testing.T, connMethod connectionMethod, config *Config, tests []subtest) {
|
||||||
|
if os.Getenv("DEX_LDAP_TESTS") == "" {
|
||||||
|
t.Skip("Specify not-empty DEX_LDAP_TESTS env variable to enable LDAP tests")
|
||||||
|
}
|
||||||
|
|
||||||
// Shallow copy.
|
// Shallow copy.
|
||||||
c := *config
|
c := *config
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user