]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
global search and replace
authorAlan T. DeKok <aland@freeradius.org>
Mon, 5 Dec 2022 03:07:27 +0000 (22:07 -0500)
committerAlan T. DeKok <aland@freeradius.org>
Mon, 5 Dec 2022 16:08:22 +0000 (11:08 -0500)
perl -p -i -e 's/\(([^ ]+) != ([^ ]+)\)/(!($1 == $2))/g'

src/tests/keywords/date
src/tests/keywords/foreach-isolation
src/tests/keywords/update-delete
src/tests/keywords/update-index
src/tests/keywords/update-prepend
src/tests/keywords/update-remove-list

index 51efd12bd2908f89a940e6aac505ad61962009bd..228593764b19ba7eb534d8185b4d0a09a3d22ba4 100644 (file)
@@ -9,7 +9,7 @@
 &Tmp-String-0 := %(date:%{Tmp-Integer-0})
 
 # Some systems report GMT some UTC...
-if (!(&Tmp-String-0 == "Fri 22 Sep 17:25:00 GMT 2017")) && (&Tmp-String-0 != "Fri 22 Sep 17:25:00 UTC 2017") {
+if (!(&Tmp-String-0 == "Fri 22 Sep 17:25:00 GMT 2017")) && (!(&Tmp-String-0 == "Fri 22 Sep 17:25:00 UTC 2017")) {
        test_fail
 }
 
index e065708ea63e1d74bfda1d7a610f5d163dc23bf8..9e795e769a11cb08512242ac0c718442712f893f 100644 (file)
@@ -17,7 +17,7 @@ if (!&Tmp-String-0[0] || !&Tmp-String-0[1] || !&Tmp-String-0[2] || !&Tmp-String-
        test_fail
 }
 
-if (!((&Tmp-String-0[0] == '0')) || (!(&Tmp-String-0[1] == '1')) || (&Tmp-String-0[2] != '2') || (&Tmp-String-0[3] != '3')) {
+if (!((&Tmp-String-0[0] == '0')) || (!(&Tmp-String-0[1] == '1')) || (!(&Tmp-String-0[2] == '2')) || (!(&Tmp-String-0[3] == '3'))) {
        test_fail
 }
 
index d01367a3d58112d9fd98a8305dc9fefbab04751c..25188d4b6e68c32ca5c53c0569c424aa0e79b601 100644 (file)
@@ -8,7 +8,7 @@ update request {
        &Tmp-IP-Address-0 := 192.0.2.1
 }
 
-if (!((&Tmp-String-0 == 'foobarbaz')) || (!(&Tmp-Integer-0 == 123456789)) || (&Tmp-IP-Address-0 != 192.0.2.1)) {
+if (!((&Tmp-String-0 == 'foobarbaz')) || (!(&Tmp-Integer-0 == 123456789)) || (!(&Tmp-IP-Address-0 == 192.0.2.1))) {
        test_fail
 }
 
index 1f02b7f5702e7966a510f63b6ac7b663296d9045..a7c3baa33e8ff2da5d2f67aba801d6b90e369a5c 100644 (file)
@@ -7,7 +7,7 @@ update {
        &control.Reply-Message += 'c'
 }
 
-if (!((&control.Reply-Message[0] == 'a')) || (!(&control.Reply-Message[1] == 'b')) || (&control.Reply-Message[2] != 'c')) {
+if (!((&control.Reply-Message[0] == 'a')) || (!(&control.Reply-Message[1] == 'b')) || (!(&control.Reply-Message[2] == 'c'))) {
        test_fail
 }
 
@@ -16,7 +16,7 @@ update {
        &control.Reply-Message[1] := 'd'
 }
 
-if (!((&control.Reply-Message[0] == 'a')) || (!(&control.Reply-Message[1] == 'd')) || (&control.Reply-Message[2] != 'c')) {
+if (!((&control.Reply-Message[0] == 'a')) || (!(&control.Reply-Message[1] == 'd')) || (!(&control.Reply-Message[2] == 'c'))) {
        test_fail
 }
 
@@ -25,7 +25,7 @@ update {
        &control.Reply-Message[0] := &control.Reply-Message[0]
 }
 
-if (!((&control.Reply-Message[0] == 'a')) || (!(&control.Reply-Message[1] == 'd')) || (&control.Reply-Message[2] != 'c')) {
+if (!((&control.Reply-Message[0] == 'a')) || (!(&control.Reply-Message[1] == 'd')) || (!(&control.Reply-Message[2] == 'c'))) {
        test_fail
 }
 
index 146c7d7acde66ec1fb64e30bc21750ea78971e4a..4666f981079bed969e7c90ff57c8b957303ea3d8 100644 (file)
@@ -47,7 +47,7 @@ update {
 }
 
 # The attributes should now be "wibble", "foo", "baz", "boink", "foo", "baz"
-if (!(("%{Tmp-String-0[0]}" == 'wibble')) || (!("%{Tmp-String-0[1]}" == 'foo')) || (!(%{Tmp-String-0[2]} == 'baz')) || ("%{Tmp-String-0[3]}" != 'boink') || ("%{Tmp-String-0[4]}" != 'foo') || ("%{Tmp-String-0[5]}" != 'baz')) {
+if (!(("%{Tmp-String-0[0]}" == 'wibble')) || (!("%{Tmp-String-0[1]}" == 'foo')) || (!(%{Tmp-String-0[2]} == 'baz')) || (!("%{Tmp-String-0[3]}" == 'boink')) || (!("%{Tmp-String-0[4]}" == 'foo')) || (!("%{Tmp-String-0[5]}" == 'baz'))) {
        test_fail
 }
 
@@ -71,7 +71,7 @@ update {
 }
 
 # The control attributes should now be "wibble", "foo", "baz", "boink", "foo", "baz", "initial"
-if (!(("%{control.Tmp-String-0[0]}" == 'wibble')) || (!("%{control.Tmp-String-0[1]}" == 'foo')) || (!(%{control.Tmp-String-0[2]} == 'baz')) || ("%{control.Tmp-String-0[3]}" != 'boink') || ("%{control.Tmp-String-0[4]}" != 'foo') || ("%{control.Tmp-String-0[5]}" != 'baz') || ("%{control.Tmp-String-0[6]}" != 'initial')) {
+if (!(("%{control.Tmp-String-0[0]}" == 'wibble')) || (!("%{control.Tmp-String-0[1]}" == 'foo')) || (!(%{control.Tmp-String-0[2]} == 'baz')) || (!("%{control.Tmp-String-0[3]}" == 'boink')) || (!("%{control.Tmp-String-0[4]}" == 'foo')) || (!("%{control.Tmp-String-0[5]}" == 'baz')) || (!("%{control.Tmp-String-0[6]}" == 'initial'))) {
        test_fail
 }
 
index d01367a3d58112d9fd98a8305dc9fefbab04751c..25188d4b6e68c32ca5c53c0569c424aa0e79b601 100644 (file)
@@ -8,7 +8,7 @@ update request {
        &Tmp-IP-Address-0 := 192.0.2.1
 }
 
-if (!((&Tmp-String-0 == 'foobarbaz')) || (!(&Tmp-Integer-0 == 123456789)) || (&Tmp-IP-Address-0 != 192.0.2.1)) {
+if (!((&Tmp-String-0 == 'foobarbaz')) || (!(&Tmp-Integer-0 == 123456789)) || (!(&Tmp-IP-Address-0 == 192.0.2.1))) {
        test_fail
 }