]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Add test for list reference in exec output parsing
authorNick Porter <nick@portercomputing.co.uk>
Tue, 31 Dec 2024 11:32:32 +0000 (11:32 +0000)
committerNick Porter <nick@portercomputing.co.uk>
Tue, 31 Dec 2024 11:32:32 +0000 (11:32 +0000)
src/tests/modules/exec/attrs.sh
src/tests/modules/exec/sync.unlang

index 727c972671212b63c96940ec335b8523e1cdfd2a..b401387b09090270296548a6df8b5cd641f61372 100755 (executable)
@@ -2,5 +2,6 @@
 
 echo Filter-Id := $1
 echo Callback-Id := \"${CALLED_STATION_ID}\"
+echo reply.Filter-Id := $1
 
 exit 0;
index f00219d19e6ac2c9cb623afcabace561fffd604b..f91b46cf58b409fb9f23bd0864de4ebc1b5496ba 100644 (file)
@@ -59,6 +59,10 @@ if ((!&control.Callback-Id) || (&control.Callback-Id != 'aabbccddeeff')) {
        test_fail
 }
 
+if ((!&reply.Filter-Id) || (&reply.Filter-Id != 'tony')) {
+       test_fail
+}
+
 #
 #  Call a module which returns status code 7 - mapped to module exit
 #  code "notfound".  Attributes in its output should be ignored.
@@ -85,4 +89,5 @@ if !(&control.Filter-Id == 'TONY') {
        test_fail
 }
 
+&reply -= &Filter-Id[*]
 test_pass