aboutsummaryrefslogtreecommitdiffstats
path: root/pkg/vminfo/linux_test.go
diff options
context:
space:
mode:
authorAleksandr Nogikh <nogikh@google.com>2025-01-24 17:08:36 +0100
committerAleksandr Nogikh <nogikh@google.com>2025-01-24 16:31:11 +0000
commit9fbd772e8b64ff0c8c90bdfb86237aefa530a06c (patch)
treeafc3a79ded0fff165a733c4ad9d20880e301137f /pkg/vminfo/linux_test.go
parent2d19ddde3e0e272bddc8220c8752c3d649459a26 (diff)
pkg/vminfo: remove Context from the constructor
The context is assumed to be passed into the function doing the actual processing. Refactor vminfo to follow this approach. This will help refactor pkg/rpcserver later.
Diffstat (limited to 'pkg/vminfo/linux_test.go')
-rw-r--r--pkg/vminfo/linux_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/vminfo/linux_test.go b/pkg/vminfo/linux_test.go
index 5be6a7a8d..3157e2b04 100644
--- a/pkg/vminfo/linux_test.go
+++ b/pkg/vminfo/linux_test.go
@@ -21,7 +21,7 @@ import (
func TestLinuxSyscalls(t *testing.T) {
cfg := testConfig(t, targets.Linux, targets.AMD64)
- checker := New(context.Background(), cfg)
+ checker := New(cfg)
filesystems := []string{
// Without sysfs, the checks would also disable mount().
"", "sysfs", "ext4", "binder", "",
@@ -40,7 +40,7 @@ func TestLinuxSyscalls(t *testing.T) {
}
stop := make(chan struct{})
go createSuccessfulResults(checker, stop)
- enabled, disabled, features, err := checker.Run(files, allFeatures())
+ enabled, disabled, features, err := checker.Run(context.Background(), files, allFeatures())
close(stop)
if err != nil {
t.Fatal(err)