Commit Graph

14 Commits

Author SHA1 Message Date
Iceber Gu
76778aee64 integration: add restart monitor test for paused task
Signed-off-by: Iceber Gu <wei.cai-nat@daocloud.io>
2023-03-15 14:32:17 +08:00
Akihiro Suda
b61988670c
go.mod: github.com/containerd/typeurl/v2 v2.1.0
Changes: https://github.com/containerd/typeurl/compare/7f6e6d160d67...v2.1.0

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2023-02-11 23:39:52 +09:00
Sebastiaan van Stijn
29c7fc9520
clean-up "nolint" comments, remove unused ones
- fix "nolint" comments to be in the correct format (`//nolint:<linters>[,<linter>`
  no leading space, required colon (`:`) and linters.
- remove "nolint" comments for errcheck, which is disabled in our config.
- remove "nolint" comments that were no longer needed (nolintlint).
- where known, add a comment describing why a "nolint" was applied.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-10-12 14:40:59 +02:00
Sebastiaan van Stijn
2e677c9329
sys: move ForceRemoveAll to integration/client
ForceRemoveAll was only used in tests/fuzzing, but added hcsshim as dependency
for the sys package. Moving this to integration/client makes the "sys" package
slightly more lightweight, and may help simplifying dependency-management.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-08-30 17:39:18 +02:00
Kazuyoshi Kato
7a834516f6 Share images between TestRestartMonitor and TestRestartMonitorWithOnFailurePolicy
These tests are launching containerd and pulling busybox there, while
other tests are using busybox from TestMain().

This commit shares busybox at least between TestRestartMonitor and
TestRestartMonitorWithOnFailurePolicy to reduce the chance of
throttling from ghcr.io.

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
2022-05-04 16:50:19 +00:00
Ye Sijun
3df7674058 add restart policy for enhanced restart manager
Signed-off-by: Ye Sijun <junnplus@gmail.com>
2022-04-09 01:04:11 +08:00
Eng Zer Jun
18ec2761c0
test: use T.TempDir to create temporary test directory
The directory created by `T.TempDir` is automatically removed when the
test and all its subtests complete.

Reference: https://pkg.go.dev/testing#T.TempDir
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2022-03-15 14:03:50 +08:00
Gabriel Adrian Samfira
b63000c65d
[Windows][Integration] Enable TestRestartMonitor
With the release of hcsshim v0.9.2, this test should pass without
issues on Windows.

Signed-off-by: Gabriel Adrian Samfira <gsamfira@cloudbasesolutions.com>
2022-02-04 17:27:14 +02:00
Derek McGowan
552a27081c
Disable restart monitor test in Windows
Skip this test until this error can be evaluated and the appropriate
test fix or environment configuration can be determined.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2021-12-10 11:43:23 -08:00
Derek McGowan
807213fd32
Update restart monitor test to output daemon logs on failure
Signed-off-by: Derek McGowan <derek@mcg.dev>
2021-12-09 11:45:37 -08:00
Derek McGowan
bae0d88ae7
Add error logging on cleanup
Check the errors for task and container deletion during restart test
cleanup.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2021-12-02 11:47:14 -08:00
Derek McGowan
54c0cdae60
Update TestRestartMonitor expected time check
Use the time for the last non-running status to determine
whether the restart did not occur as expected. The
current timestamp only accounts for when the running
status was seen, however, the restart would have always
occurred in between the previous check and latest check.
Therefore, it makes more sense to use the previous check
to determine whether a failure was seen from the restart
monitor not restarting as expected.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2021-11-04 09:42:58 -07:00
David Porter
9bfec3980b test: Add grace period for restart monitor test
restart monitor test was failing due to occasionally taking past the
deadline on windows tests. Add a small additional grace period to
deflake the test.

Signed-off-by: David Porter <porterdavid@google.com>
2021-11-03 14:07:11 -07:00
Claudiu Belu
830b3c26ec integration: Enable some tests for Windows (part 2)
Some of the tests that are currently running only on Linux can be made
to run on Windows with a few changes.

Signed-off-by: Claudiu Belu <cbelu@cloudbasesolutions.com>
2021-10-07 08:13:01 -07:00