test-client: fix quotation in expected message

With the newer glib and libc in F42 and Ubuntu devel, the
"{left,right} double quotation mark" characters are printed in the
output message. The double quotation marks are multi-byte characters
and they can't be matched using a character class []. Update the
regexp accordingly.

(cherry picked from commit 5ad712974e)
This commit is contained in:
Beniamino Galvani 2025-09-03 16:40:47 +02:00 committed by Íñigo Huguet
parent 1f23bb18ad
commit cb61701649

View file

@ -2247,9 +2247,9 @@ class TestNmcli(unittest.TestCase):
extra_env=no_dbus_env,
replace_stderr=[
Util.ReplaceTextRegex(
# depending on glib version, it prints `%s', '%s', or “%s”.
# depending on libc version, it converts unicode to ? or *.
r"Key/Value pair 0, [`*?']invalid[*?'], in address element [`*?']very:invalid[*?'] does not contain an equal sign",
# Depending on glib version, it prints `%s', '%s', or “%s”.
# Some libc versions convert the multi-byte UTF-8 sequence to ? or *.
r"Key/Value pair 0, .*invalid.*, in address element .*very:invalid.* does not contain an equal sign",
"Key/Value pair 0, 'invalid', in address element 'very:invalid' does not contain an equal sign",
)
],