moby/integration/container
Paweł Gronowski c6031ad519
integration: Don't env cleanup before parallel subtests
Calling function returned from setupTest (which calls testEnv.Clean) in
a defer block inside a test that spawns parallel subtests caused the
cleanup function to be called before any of the subtest did anything.

Change the defer expressions to use `t.Cleanup` instead to call it only
after all subtests have also finished.
This only changes tests which have parallel subtests.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
(cherry picked from commit f9e2eed55d)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2023-07-13 15:07:08 +02:00
..
attach_test.go Make it explicit raw|multiplexed stream implementation being used 2022-05-12 11:36:31 +02:00
checkpoint_test.go unused: ignore false positives 2021-06-10 13:03:32 +02:00
container_test.go integration: Don't env cleanup before parallel subtests 2023-07-13 15:07:08 +02:00
copy_test.go client: CopyToContainer(), CopyFromContainer(): remove status-code handling 2022-04-19 08:28:20 +02:00
create_test.go integration: Don't env cleanup before parallel subtests 2023-07-13 15:07:08 +02:00
daemon_linux_test.go integration: disable iptables in parallel tests 2023-07-07 15:48:05 -04:00
daemon_test.go integration: disable iptables in parallel tests 2023-07-07 15:48:05 -04:00
devices_windows_test.go integration: Don't env cleanup before parallel subtests 2023-07-13 15:07:08 +02:00
diff_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-11 00:06:42 +01:00
exec_linux_test.go container/exec: Support ConsoleSize 2022-06-24 11:54:25 +02:00
exec_test.go refactor: move from io/ioutil to io and os package 2021-08-27 14:56:57 +08:00
export_test.go Using test names instead of hardcoded ones in integration/container directory 2020-05-18 16:37:04 +01:00
health_test.go daemon: kill exec process on ctx cancel 2022-08-23 22:09:40 +02:00
inspect_test.go Using test names instead of hardcoded ones in integration/container directory 2020-05-18 16:37:04 +01:00
ipcmode_linux_test.go rootless: support --ipc=host 2023-01-20 17:02:23 +01:00
kill_test.go vendor: github.com/moby/sys/mount v0.3.0, mountinfo v0.5.0, signal v0.6.0, symlink v0.2.0 2021-11-19 09:56:37 +01:00
links_linux_test.go refactor: move from io/ioutil to io and os package 2021-08-27 14:56:57 +08:00
logs_test.go TestLogs: Increase stop check poll timeout on Windows 2023-04-21 12:26:59 +02:00
main_test.go testutil: make testing packages public 2019-09-11 07:47:23 -05:00
mounts_linux_test.go integration: Don't env cleanup before parallel subtests 2023-07-13 15:07:08 +02:00
nat_test.go integration: TestNetworkLoopbackNat is broken on GitHub Runner 2022-09-08 13:50:18 +02:00
pause_test.go client: ContainerStop(), ContainerRestart(): support stop-signal 2022-04-20 21:29:34 +02:00
pidmode_linux_test.go rootless: support --pid=host 2021-02-01 14:55:18 +09:00
ps_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-11 00:06:42 +01:00
remove_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-11 00:06:42 +01:00
rename_test.go client: ContainerStop(), ContainerRestart(): support stop-signal 2022-04-20 21:29:34 +02:00
resize_test.go Prepare tests for Windows containerd support 2021-04-22 10:50:00 +03:00
restart_test.go TestDaemonRestartKillContainers: Fix loop capture 2023-03-22 15:36:41 +01:00
run_cgroupns_linux_test.go integration: port TestRunModePIDHost from CLI test to API test 2021-02-01 14:54:07 +09:00
run_linux_test.go Allow containerd shim refs in default-runtime 2022-08-18 18:51:23 +00:00
stats_test.go Merge pull request #40478 from cpuguy83/dont-prime-the-stats 2020-04-16 20:57:06 +02:00
stop_linux_test.go integration: Don't env cleanup before parallel subtests 2023-07-13 15:07:08 +02:00
stop_test.go client: ContainerStop(), ContainerRestart(): support stop-signal 2022-04-20 21:29:34 +02:00
stop_windows_test.go integration: Don't env cleanup before parallel subtests 2023-07-13 15:07:08 +02:00
update_linux_test.go test-integration: support cgroup2 2020-06-22 14:17:45 +09:00
update_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-11 00:06:42 +01:00
wait_test.go integration: Don't env cleanup before parallel subtests 2023-07-13 15:07:08 +02:00