Lines Matching refs:ASSERT_EQ
78 ASSERT_EQ(system("ip link set dev " netkit_name in create_netkit()
116 ASSERT_EQ(if_nametoindex(netkit_name), 0, netkit_name "_ifindex"); in destroy_netkit()
182 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc1, in serial_test_tc_netkit_basic()
184 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc2, in serial_test_tc_netkit_basic()
199 ASSERT_EQ(skel->bss->seen_tc1, false, "seen_tc1"); in serial_test_tc_netkit_basic()
200 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_basic()
224 ASSERT_EQ(optq.count, 1, "count"); in serial_test_tc_netkit_basic()
225 ASSERT_EQ(optq.revision, 2, "revision"); in serial_test_tc_netkit_basic()
226 ASSERT_EQ(optq.prog_ids[0], pid1, "prog_ids[0]"); in serial_test_tc_netkit_basic()
227 ASSERT_EQ(optq.link_ids[0], lid1, "link_ids[0]"); in serial_test_tc_netkit_basic()
228 ASSERT_EQ(optq.prog_ids[1], 0, "prog_ids[1]"); in serial_test_tc_netkit_basic()
229 ASSERT_EQ(optq.link_ids[1], 0, "link_ids[1]"); in serial_test_tc_netkit_basic()
232 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_basic()
234 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_basic()
235 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_basic()
257 ASSERT_EQ(optq.count, 1, "count"); in serial_test_tc_netkit_basic()
258 ASSERT_EQ(optq.revision, 2, "revision"); in serial_test_tc_netkit_basic()
259 ASSERT_EQ(optq.prog_ids[0], pid2, "prog_ids[0]"); in serial_test_tc_netkit_basic()
260 ASSERT_EQ(optq.link_ids[0], lid2, "link_ids[0]"); in serial_test_tc_netkit_basic()
261 ASSERT_EQ(optq.prog_ids[1], 0, "prog_ids[1]"); in serial_test_tc_netkit_basic()
262 ASSERT_EQ(optq.link_ids[1], 0, "link_ids[1]"); in serial_test_tc_netkit_basic()
265 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_basic()
267 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_basic()
268 ASSERT_EQ(skel->bss->seen_tc2, true, "seen_tc2"); in serial_test_tc_netkit_basic()
296 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc1, in serial_test_tc_netkit_multi_links_target()
298 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc2, in serial_test_tc_netkit_multi_links_target()
312 ASSERT_EQ(skel->bss->seen_tc1, false, "seen_tc1"); in serial_test_tc_netkit_multi_links_target()
313 ASSERT_EQ(skel->bss->seen_eth, false, "seen_eth"); in serial_test_tc_netkit_multi_links_target()
314 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_multi_links_target()
337 ASSERT_EQ(optq.count, 1, "count"); in serial_test_tc_netkit_multi_links_target()
338 ASSERT_EQ(optq.revision, 2, "revision"); in serial_test_tc_netkit_multi_links_target()
339 ASSERT_EQ(optq.prog_ids[0], pid1, "prog_ids[0]"); in serial_test_tc_netkit_multi_links_target()
340 ASSERT_EQ(optq.link_ids[0], lid1, "link_ids[0]"); in serial_test_tc_netkit_multi_links_target()
341 ASSERT_EQ(optq.prog_ids[1], 0, "prog_ids[1]"); in serial_test_tc_netkit_multi_links_target()
342 ASSERT_EQ(optq.link_ids[1], 0, "link_ids[1]"); in serial_test_tc_netkit_multi_links_target()
345 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_multi_links_target()
347 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_multi_links_target()
348 ASSERT_EQ(skel->bss->seen_eth, true, "seen_eth"); in serial_test_tc_netkit_multi_links_target()
349 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_multi_links_target()
375 ASSERT_EQ(optq.count, 2, "count"); in serial_test_tc_netkit_multi_links_target()
376 ASSERT_EQ(optq.revision, 3, "revision"); in serial_test_tc_netkit_multi_links_target()
377 ASSERT_EQ(optq.prog_ids[0], pid2, "prog_ids[0]"); in serial_test_tc_netkit_multi_links_target()
378 ASSERT_EQ(optq.link_ids[0], lid2, "link_ids[0]"); in serial_test_tc_netkit_multi_links_target()
379 ASSERT_EQ(optq.prog_ids[1], pid1, "prog_ids[1]"); in serial_test_tc_netkit_multi_links_target()
380 ASSERT_EQ(optq.link_ids[1], lid1, "link_ids[1]"); in serial_test_tc_netkit_multi_links_target()
381 ASSERT_EQ(optq.prog_ids[2], 0, "prog_ids[2]"); in serial_test_tc_netkit_multi_links_target()
382 ASSERT_EQ(optq.link_ids[2], 0, "link_ids[2]"); in serial_test_tc_netkit_multi_links_target()
385 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_multi_links_target()
387 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_multi_links_target()
388 ASSERT_EQ(skel->bss->seen_eth, true, "seen_eth"); in serial_test_tc_netkit_multi_links_target()
389 ASSERT_EQ(skel->bss->seen_tc2, true, "seen_tc2"); in serial_test_tc_netkit_multi_links_target()
434 ASSERT_EQ(skel->bss->seen_tc1, false, "seen_tc1"); in serial_test_tc_netkit_multi_opts_target()
435 ASSERT_EQ(skel->bss->seen_eth, false, "seen_eth"); in serial_test_tc_netkit_multi_opts_target()
436 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_multi_opts_target()
439 if (!ASSERT_EQ(err, 0, "prog_attach")) in serial_test_tc_netkit_multi_opts_target()
453 ASSERT_EQ(optq.count, 1, "count"); in serial_test_tc_netkit_multi_opts_target()
454 ASSERT_EQ(optq.revision, 2, "revision"); in serial_test_tc_netkit_multi_opts_target()
455 ASSERT_EQ(optq.prog_ids[0], pid1, "prog_ids[0]"); in serial_test_tc_netkit_multi_opts_target()
456 ASSERT_EQ(optq.prog_ids[1], 0, "prog_ids[1]"); in serial_test_tc_netkit_multi_opts_target()
459 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_multi_opts_target()
461 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_multi_opts_target()
462 ASSERT_EQ(skel->bss->seen_eth, true, "seen_eth"); in serial_test_tc_netkit_multi_opts_target()
463 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_multi_opts_target()
471 if (!ASSERT_EQ(err, 0, "prog_attach")) in serial_test_tc_netkit_multi_opts_target()
483 ASSERT_EQ(optq.count, 2, "count"); in serial_test_tc_netkit_multi_opts_target()
484 ASSERT_EQ(optq.revision, 3, "revision"); in serial_test_tc_netkit_multi_opts_target()
485 ASSERT_EQ(optq.prog_ids[0], pid2, "prog_ids[0]"); in serial_test_tc_netkit_multi_opts_target()
486 ASSERT_EQ(optq.prog_ids[1], pid1, "prog_ids[1]"); in serial_test_tc_netkit_multi_opts_target()
487 ASSERT_EQ(optq.prog_ids[2], 0, "prog_ids[2]"); in serial_test_tc_netkit_multi_opts_target()
490 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_multi_opts_target()
492 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_multi_opts_target()
493 ASSERT_EQ(skel->bss->seen_eth, true, "seen_eth"); in serial_test_tc_netkit_multi_opts_target()
494 ASSERT_EQ(skel->bss->seen_tc2, true, "seen_tc2"); in serial_test_tc_netkit_multi_opts_target()
541 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc1, in serial_test_tc_netkit_device()
543 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc2, in serial_test_tc_netkit_device()
545 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc3, in serial_test_tc_netkit_device()
560 ASSERT_EQ(skel->bss->seen_tc1, false, "seen_tc1"); in serial_test_tc_netkit_device()
561 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_device()
585 ASSERT_EQ(optq.count, 1, "count"); in serial_test_tc_netkit_device()
586 ASSERT_EQ(optq.revision, 2, "revision"); in serial_test_tc_netkit_device()
587 ASSERT_EQ(optq.prog_ids[0], pid1, "prog_ids[0]"); in serial_test_tc_netkit_device()
588 ASSERT_EQ(optq.link_ids[0], lid1, "link_ids[0]"); in serial_test_tc_netkit_device()
589 ASSERT_EQ(optq.prog_ids[1], 0, "prog_ids[1]"); in serial_test_tc_netkit_device()
590 ASSERT_EQ(optq.link_ids[1], 0, "link_ids[1]"); in serial_test_tc_netkit_device()
593 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_device()
595 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_device()
596 ASSERT_EQ(skel->bss->seen_tc2, false, "seen_tc2"); in serial_test_tc_netkit_device()
603 ASSERT_EQ(err, -EACCES, "prog_query_should_fail"); in serial_test_tc_netkit_device()
606 ASSERT_EQ(err, -EACCES, "prog_query_should_fail"); in serial_test_tc_netkit_device()
649 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc1, in serial_test_tc_netkit_neigh_links_target()
660 ASSERT_EQ(skel->bss->seen_tc1, false, "seen_tc1"); in serial_test_tc_netkit_neigh_links_target()
661 ASSERT_EQ(skel->bss->seen_eth, false, "seen_eth"); in serial_test_tc_netkit_neigh_links_target()
684 ASSERT_EQ(optq.count, 1, "count"); in serial_test_tc_netkit_neigh_links_target()
685 ASSERT_EQ(optq.revision, 2, "revision"); in serial_test_tc_netkit_neigh_links_target()
686 ASSERT_EQ(optq.prog_ids[0], pid1, "prog_ids[0]"); in serial_test_tc_netkit_neigh_links_target()
687 ASSERT_EQ(optq.link_ids[0], lid1, "link_ids[0]"); in serial_test_tc_netkit_neigh_links_target()
688 ASSERT_EQ(optq.prog_ids[1], 0, "prog_ids[1]"); in serial_test_tc_netkit_neigh_links_target()
689 ASSERT_EQ(optq.link_ids[1], 0, "link_ids[1]"); in serial_test_tc_netkit_neigh_links_target()
692 ASSERT_EQ(__send_icmp(ping_addr_noneigh), 0, "icmp_pkt"); in serial_test_tc_netkit_neigh_links_target()
694 ASSERT_EQ(skel->bss->seen_tc1, true /* L2: ARP */, "seen_tc1"); in serial_test_tc_netkit_neigh_links_target()
695 ASSERT_EQ(skel->bss->seen_eth, mode == NETKIT_L3, "seen_eth"); in serial_test_tc_netkit_neigh_links_target()
729 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc1, in serial_test_tc_netkit_pkt_type_mode()
731 ASSERT_EQ(bpf_program__set_expected_attach_type(skel->progs.tc7, in serial_test_tc_netkit_pkt_type_mode()
763 ASSERT_EQ(send_icmp(), 0, "icmp_pkt"); in serial_test_tc_netkit_pkt_type_mode()
765 ASSERT_EQ(skel->bss->seen_tc1, true, "seen_tc1"); in serial_test_tc_netkit_pkt_type_mode()
766 ASSERT_EQ(skel->bss->seen_tc7, true, "seen_tc7"); in serial_test_tc_netkit_pkt_type_mode()
768 ASSERT_EQ(skel->bss->seen_host, true, "seen_host"); in serial_test_tc_netkit_pkt_type_mode()
769 ASSERT_EQ(skel->bss->seen_mcast, true, "seen_mcast"); in serial_test_tc_netkit_pkt_type_mode()