tests: accommodate BSD getopt
authorEric Blake <ebb9@byu.net>
Fri, 23 Oct 2009 21:35:41 +0000 (15:35 -0600)
committerEric Blake <ebb9@byu.net>
Fri, 23 Oct 2009 22:24:02 +0000 (16:24 -0600)
* tests/misc/invalid-opt (err_subst): Support alternate spelling.

tests/misc/invalid-opt

index d251cb8..23142bb 100755 (executable)
@@ -76,7 +76,8 @@ foreach my $prog (@built_programs)
 
     # Accommodate different syntax in glibc's getopt
     # diagnostics by filtering out single quotes.
-    my $err_subst = "s,'/',/,";
+    # Also accommodate BSD getopt.
+    my $err_subst = "s,'/',/,; s,unknown,invalid,";
 
     # Depending on how this script is run, stty emits different
     # diagnostics.  Don't bother checking them.