Skip to content

Commit

Permalink
Add check to skip test setup in TestMain
Browse files Browse the repository at this point in the history
  • Loading branch information
denisonbarbosa committed Jan 2, 2024
1 parent ba7a274 commit 23d4351
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pam/integration-tests/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,11 @@ func saveArtifactsForDebug(t *testing.T, artifacts []string) {
}

func TestMain(m *testing.M) {
// Needed to skip the test setup when running the gpasswd mock.
if os.Getenv("GO_WANT_HELPER_PROCESS") != "" {
os.Exit(m.Run())
}

testutils.InstallUpdateFlag()
flag.Parse()

Expand Down

0 comments on commit 23d4351

Please sign in to comment.