RE: multiattribute testing in git 1411859
Hi Arran, Is the test cases directory thing documented somewhere? I just echo this lot to a file under policy.conf and reference it from default, but I guess from your reply that's not what you're after..? my-regexp=(.*) my-policy { update control { Tmp-String-0 := "ssid=ABCDEF" Tmp-String-0 += "ssid=GHIJKL" } if (User-Name) { foreach control:Tmp-String-0 { if ("%{Foreach-Variable-0}" =~ /${policy.my-regexp}/) { update control { SSID := "%{1}" } } } } foreach control:Tmp-String-0 { if ("%{Foreach-Variable-0}" =~ /${policy.my-regexp}/) { update control { SSID := "%{1}" } } } -----Original Message----- From: freeradius-users-bounces+andy.franks=sath.nhs.uk@lists.freeradius.org [mailto:freeradius-users-bounces+andy.franks=sath.nhs.uk@lists.freeradiu s.org] On Behalf Of Arran Cudbard-Bell Sent: 08 August 2014 22:10 To: FreeRadius users mailing list Subject: Re: multiattribute testing in git 1411859 On 6 Aug 2014, at 17:02, Franks Andy (RLZ) IT Systems Engineer <Andy.Franks@sath.nhs.uk> wrote:
Thanks Arran for taking the time to reply in-depth. I did send a test case over on skype?
Needs to be in a format I can just drop in the test cases dir and see fail. -Arran Arran Cudbard-Bell <a.cudbardb@freeradius.org> FreeRADIUS development team FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2
Franks Andy (RLZ) IT Systems Engineer wrote:
Is the test cases directory thing documented somewhere?
No. It's for developers, who are few in number.
I just echo this lot to a file under policy.conf and reference it from default, but I guess from your reply that's not what you're after..?
No. See src/tests/foreach*. Don't use a policy, just copy one of the "foreach" examples, and edit it. Alan DeKok.
participants (2)
-
Alan DeKok -
Franks Andy (RLZ) IT Systems Engineer