Skip to content

Commit

Permalink
tests: Add missing reset_pcap_file() definition to EDNS test.
Browse files Browse the repository at this point in the history
When backporting f22a1ba ("Skip only OVN DNS responder packets from
OUT_ACL.") we missed the fact that on branch-22.03 reset_pcap_file() had
not been factored out as a standalone helper.  That is, commit
8f841ec ("tests: Factor out reset_pcap_file() helper.") is missing
on branch 22.03.

For simplicity, adapt the EDNS test to include its own definition of the
helper (similar to other tests on the 22.03 branch).

Fixes: f22a1ba ("Skip only OVN DNS responder packets from OUT_ACL.")
Signed-off-by: Dumitru Ceara <[email protected]>
Acked-by: Mark Michelson <[email protected]>
  • Loading branch information
dceara committed Jan 22, 2025
1 parent c50816b commit 63de413
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/ovn.at
Original file line number Diff line number Diff line change
Expand Up @@ -10904,6 +10904,16 @@ OVN_POPULATE_ARP
wait_for_ports_up
check ovn-nbctl --wait=hv sync

reset_pcap_file() {
local iface=$1
local pcap_file=$2
check ovs-vsctl -- set Interface $iface options:tx_pcap=dummy-tx.pcap \
options:rxq_pcap=dummy-rx.pcap
rm -f ${pcap_file}*.pcap
check ovs-vsctl -- set Interface $iface options:tx_pcap=${pcap_file}-tx.pcap \
options:rxq_pcap=${pcap_file}-rx.pcap
}

dns_req=$(fmt_pkt "Ether(dst='00:00:00:00:00:02', src='00:00:00:00:00:01') / \
IP(dst='10.0.0.254', src='10.0.0.1') / \
UDP(sport=42424, dport=53) / \
Expand Down

0 comments on commit 63de413

Please sign in to comment.