From a6b2e823eeb58a75222bff5bd5d1e68cb8e37647 Mon Sep 17 00:00:00 2001 From: "Alan T. DeKok" Date: Fri, 29 Sep 2023 10:26:06 -0400 Subject: [PATCH] wrap tests in group { ... } so the tests can declare local variables --- src/tests/keywords/dhcpv4.conf | 12 +++++++++--- src/tests/keywords/dhcpv6.conf | 12 +++++++++--- src/tests/keywords/radius.conf | 12 +++++++++--- 3 files changed, 27 insertions(+), 9 deletions(-) diff --git a/src/tests/keywords/dhcpv4.conf b/src/tests/keywords/dhcpv4.conf index bd7e67edfc..841f4ae1e2 100644 --- a/src/tests/keywords/dhcpv4.conf +++ b/src/tests/keywords/dhcpv4.conf @@ -44,9 +44,15 @@ server default { recv Discover { # - # Include the test file specified by the - # KEYWORD environment variable. + # Include the test file specified by the + # KEYWORD environment variable. # - $INCLUDE ${keyword}/$ENV{KEYWORD} + # Wrap it in a "group" so that the test + # can put local variable definitions at the + # top of the file. + # + group { + $INCLUDE ${keyword}/$ENV{KEYWORD} + } } } diff --git a/src/tests/keywords/dhcpv6.conf b/src/tests/keywords/dhcpv6.conf index 7176367a8a..981bbc20fb 100644 --- a/src/tests/keywords/dhcpv6.conf +++ b/src/tests/keywords/dhcpv6.conf @@ -44,9 +44,15 @@ server default { recv Solicit { # - # Include the test file specified by the - # KEYWORD environment variable. + # Include the test file specified by the + # KEYWORD environment variable. # - $INCLUDE ${keyword}/$ENV{KEYWORD} + # Wrap it in a "group" so that the test + # can put local variable definitions at the + # top of the file. + # + group { + $INCLUDE ${keyword}/$ENV{KEYWORD} + } } } diff --git a/src/tests/keywords/radius.conf b/src/tests/keywords/radius.conf index fc9113326e..245a969665 100644 --- a/src/tests/keywords/radius.conf +++ b/src/tests/keywords/radius.conf @@ -131,10 +131,16 @@ server default { &control.Password.Cleartext := "hello" # - # Include the test file specified by the - # KEYWORD environment variable. + # Include the test file specified by the + # KEYWORD environment variable. # - $INCLUDE ${keyword}/$ENV{KEYWORD} + # Wrap it in a "group" so that the test + # can put local variable definitions at the + # top of the file. + # + group { + $INCLUDE ${keyword}/$ENV{KEYWORD} + } if (&control.Password.Cleartext) { pap -- 2.47.3