test(agent/reaper): Fix restructure issue (#7168)

In #7164 we accidentally removed the "in CI" check, this fixes it.
This commit is contained in:
Mathias Fredriksson 2023-04-17 20:39:10 +03:00 committed by GitHub
parent bb3b8bab78
commit b3b26a62f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 8 deletions

View File

@ -18,7 +18,11 @@ import (
"github.com/coder/coder/testutil"
)
//nolint:paralleltest // Non-parallel subtest.
// TestReap checks that's the reaper is successfully reaping
// exited processes and passing the PIDs through the shared
// channel.
//
//nolint:paralleltest
func TestReap(t *testing.T) {
// Don't run the reaper test in CI. It does weird
// things like forkexecing which may have unintended
@ -27,13 +31,6 @@ func TestReap(t *testing.T) {
t.Skip("Detected CI, skipping reaper tests")
}
// OK checks that's the reaper is successfully reaping
// exited processes and passing the PIDs through the shared
// channel.
}
//nolint:paralleltest // Signal handling.
func TestReap_OK(t *testing.T) {
pids := make(reap.PidCh, 1)
err := reaper.ForkReap(
reaper.WithPIDCallback(pids),