test(integration): use stopProc in package tests#7839
Conversation
Replace direct proc.kill() teardown in package-hosted integration specs with await stopProc(proc). This makes process shutdown consistent with the root integration tests and reduces flakiness from leaked child process state. Add an optional signal to preserve the existing SIGINT-based Azure teardown behavior.
Overall package sizeSelf size: 5.04 MB Dependency sizes| name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 3.0.0 | 81.15 kB | 815.98 kB | | dc-polyfill | 0.1.10 | 26.73 kB | 26.73 kB |🤖 This report was automatically generated by heaviest-objects-in-the-universe |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #7839 +/- ##
=======================================
Coverage 80.48% 80.48%
=======================================
Files 749 749
Lines 32457 32457
=======================================
Hits 26124 26124
Misses 6333 6333 Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This comment has been minimized.
This comment has been minimized.
BenchmarksBenchmark execution time: 2026-03-23 09:41:40 Comparing candidate commit 5fa3ab2 in PR branch Found 0 performance improvements and 0 performance regressions! Performance is the same for 229 metrics, 31 unstable metrics. |
Replace direct proc.kill() teardown in package-hosted integration specs with await stopProc(proc). This makes process shutdown consistent with the root integration tests and reduces flakiness from leaked child process state. Add an optional signal to preserve the existing SIGINT-based Azure teardown behavior.
Replace direct proc.kill() teardown in package-hosted integration specs with await stopProc(proc). This makes process shutdown consistent with the root integration tests and reduces flakiness from leaked child process state. Add an optional signal to preserve the existing SIGINT-based Azure teardown behavior.

What does this PR do?
Follow up on #7661 by applying the same process teardown cleanup to package-hosted integration tests under
packages/.This replaces direct
proc.kill()calls in test teardown with the sharedstopProchelper so the child process is fully stopped before the next test runs. For the Azure-hosted tests,stopProcnow accepts an optional initial signal so they can keep usingSIGINTbefore falling back toSIGKILLif needed.Motivation
#7661 made this change for tests in the root
integration-tests/directory, but there were still package-level integration tests using direct process termination.This brings those remaining tests onto the same teardown path to reduce flakiness from leaked child processes and make integration test cleanup behavior consistent across the repo.