summaryrefslogtreecommitdiff
path: root/integrationtests/fcntl_test.go
blob: f9c95bd496d085b9afe5cc8bb12fce024a9dcca1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package integrationtests

import "testing"

func TestFcntlDupfd(t *testing.T) {
	runScenario(t, "fcntl-dupfd", []ExpectedEvent{
		{
			PathContains: "fcntlfile.txt",
			Tracepoint:   "enter_fcntl",
			Comm:         "ioworkload",
			MinCount:     1,
		},
	})
}

func TestFcntlSetfl(t *testing.T) {
	runScenario(t, "fcntl-setfl", []ExpectedEvent{
		{
			PathContains: "fcntlsetflfile.txt",
			Tracepoint:   "enter_fcntl",
			Comm:         "ioworkload",
			MinCount:     2,
		},
	})
}

func TestFcntlDupfdCloexec(t *testing.T) {
	runScenario(t, "fcntl-dupfd-cloexec", []ExpectedEvent{
		{
			PathContains: "fcntlcloexecfile.txt",
			Tracepoint:   "enter_fcntl",
			Comm:         "ioworkload",
			MinCount:     1,
		},
	})
}