diff options
| author | Paul Chaignon <paul.chaignon@gmail.com> | 2023-10-06 20:16:10 +0200 |
|---|---|---|
| committer | Aleksandr Nogikh <nogikh@google.com> | 2023-10-09 10:22:31 +0000 |
| commit | 22d57370e2f9ac0581d3a6257030c79b3d758855 (patch) | |
| tree | 78948e946ea1c20e460382982e2e941c68ea78ea /prog/resources_test.go | |
| parent | f5ee62f7ee98f53dced33b767e59f47b35017568 (diff) | |
prog: more complex tests for getInputResources
This commit adds more complex unit tests to cover the bug in
getInputResources fixed by the previous commit.
required_res1 and test_args3 covers the case where a struct is included
both as optional and required. required_res2 and test_args4 cover the
case where a struct is included both as DirOut and DirIn. In both cases
the resource should be recognized as being a required input resource for
the syscall.
Signed-off-by: Paul Chaignon <paul.chaignon@gmail.com>
Diffstat (limited to 'prog/resources_test.go')
| -rw-r--r-- | prog/resources_test.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/prog/resources_test.go b/prog/resources_test.go index 8db8dbd17..222e93c00 100644 --- a/prog/resources_test.go +++ b/prog/resources_test.go @@ -101,6 +101,7 @@ func TestTransitivelyEnabledCallsLinux(t *testing.T) { func TestGetInputResources(t *testing.T) { expectedRequiredResources := map[string]bool{ "required_res1": false, + "required_res2": false, } t.Parallel() |
