From 0d87e4643410e4de8645abb332d9bce61eff0c28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marco=20Trevisan=20=28Trevi=C3=B1o=29?= Date: Mon, 8 Apr 2024 00:30:36 +0200 Subject: [PATCH] pam/integration-tests: Run tests using the exec module with GDM too --- pam/integration-tests/gdm_test.go | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/pam/integration-tests/gdm_test.go b/pam/integration-tests/gdm_test.go index f98e6c36c..a3bef7836 100644 --- a/pam/integration-tests/gdm_test.go +++ b/pam/integration-tests/gdm_test.go @@ -365,9 +365,19 @@ func TestGdmModuleWithCWrapper(t *testing.T) { t.Parallel() t.Cleanup(pam_test.MaybeDoLeakCheck) - wrapperLibPath := buildPAMWrapperModule(t) - libPath := buildPAMModule(t) - testGdmModule(t, wrapperLibPath, []string{libPath}) + execLib := buildExecModule(t) + cliPath := buildPAMClient(t) + moduleArgs := []string{"--exec-debug"} + if !testutils.IsVerbose() { + logFile := prepareFileLogging(t, "exec-module.log") + saveArtifactsForDebug(t, []string{logFile}) + moduleArgs = append(moduleArgs, "--exec-log", logFile) + } + if env := testutils.CoverDirEnv(); env != "" { + moduleArgs = append(moduleArgs, "--exec-env", testutils.CoverDirEnv()) + } + moduleArgs = append(moduleArgs, "--", cliPath) + testGdmModule(t, execLib, moduleArgs) } func buildPAMModule(t *testing.T) string {