diff mbox series

[ovs-dev,1/2] tests: Use grep -E and grep -F instead of obsolete egrep/fgrep.

Message ID 166479338598.310761.15892760832452456419.stgit@dceara.remote.csb
State Accepted
Headers show
Series Port OVS test and checkpatch enhancements. | expand

Checks

Context Check Description
ovsrobot/apply-robot success apply and check: success

Commit Message

Dumitru Ceara Oct. 3, 2022, 10:36 a.m. UTC
Inspired by Andreas Stieger's OVS commit 75c355adc057 ("tests: Fix tests
with GNU grep 3.8."):
https://github.com/openvswitch/ovs/commit/75c355adc057

Signed-off-by: Dumitru Ceara <dceara@redhat.com>
---
 tests/ovn-nbctl.at |    2 +-
 tests/ovn.at       |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/tests/ovn-nbctl.at b/tests/ovn-nbctl.at
index 6a5d52a5da..4d480e3573 100644
--- a/tests/ovn-nbctl.at
+++ b/tests/ovn-nbctl.at
@@ -2276,7 +2276,7 @@  AT_CHECK([grep 'missing argument to .* option' stderr], [0], [ignore])
 
 dnl Unexpected option argument
 AT_CHECK([ovn-nbctl --if-exists=foo list Logical_Switch], [1], [], [stderr])
-AT_CHECK([egrep 'option .* doesn'\''t allow an argument|option .* requires an argument' stderr], [0], [ignore])
+AT_CHECK([grep -E 'option .* doesn'\''t allow an argument|option .* requires an argument' stderr], [0], [ignore])
 
 AT_CHECK([ovn-nbctl -- --if-exists=foo list Logical_Switch], [1], [], [stderr])
 AT_CHECK([grep 'option on .* does not accept an argument' stderr], [0], [ignore])
diff --git a/tests/ovn.at b/tests/ovn.at
index 0dc23dbd22..f8b8db4df8 100644
--- a/tests/ovn.at
+++ b/tests/ovn.at
@@ -6882,7 +6882,7 @@  ciaddr=`ip_to_hex 0 0 0 0`
 request_ip=0
 expected_dhcp_opts=""
 test_dhcp 18 1 f00000000001 04 0 $ciaddr $offer_ip $request_ip 0 0 ff1000000001 $server_ip 02 $expected_dhcp_opts
-AT_CHECK([fgrep -iq 'DHCPDECLINE from f0:00:00:00:00:01, 10.0.0.4 duplicated' hv1/ovn-controller.log], [0], [])
+AT_CHECK([grep -F -iq 'DHCPDECLINE from f0:00:00:00:00:01, 10.0.0.4 duplicated' hv1/ovn-controller.log], [0], [])
 
 # Send Etherboot.