1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
12 check "gopkg.in/check.v1"
15 func haveDocker() bool {
16 _, err := exec.Command("docker", "info").CombinedOutput()
20 func (s *LDAPSuite) TestLoginLDAPViaPAM(c *check.C) {
22 c.Skip("skipping docker test in short mode")
25 c.Skip("skipping docker test because docker is not available")
27 pgproxy := newPgProxy(c, s.cluster)
30 cmd := exec.Command("bash", "login_ldap_docker_test.sh")
31 cmd.Stdout = os.Stderr
32 cmd.Stderr = os.Stderr
33 cmd.Env = append(os.Environ(), "config_method=pam", "pgport="+pgproxy.Port())
35 c.Check(err, check.IsNil)
38 func (s *LDAPSuite) TestLoginLDAPBuiltin(c *check.C) {
40 c.Skip("skipping docker test in short mode")
43 c.Skip("skipping docker test because docker is not available")
45 pgproxy := newPgProxy(c, s.cluster)
48 cmd := exec.Command("bash", "login_ldap_docker_test.sh")
49 cmd.Stdout = os.Stderr
50 cmd.Stderr = os.Stderr
51 cmd.Env = append(os.Environ(), "config_method=ldap", "pgport="+pgproxy.Port())
53 c.Check(err, check.IsNil)