MCPcopy
hub / github.com/cilium/ebpf / TestProgramKernelVersion

Function TestProgramKernelVersion

prog_test.go:298–310  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

296}
297
298func TestProgramKernelVersion(t *testing.T) {
299 testutils.SkipOnOldKernel(t, "4.20", "KernelVersion")
300
301 _ = mustNewProgram(t, &ProgramSpec{
302 Type: Kprobe,
303 Instructions: asm.Instructions{
304 asm.LoadImm(asm.R0, 0, asm.DWord),
305 asm.Return(),
306 },
307 KernelVersion: 42,
308 License: "MIT",
309 }, nil)
310}
311
312func TestProgramVerifierLog(t *testing.T) {
313 check := func(t *testing.T, err error) {

Callers

nothing calls this directly

Calls 4

SkipOnOldKernelFunction · 0.92
LoadImmFunction · 0.92
ReturnFunction · 0.92
mustNewProgramFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…