From bd6d0b8e54f1b4e510fc4ab1f5e78e86019d6ee9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ond=C5=99ej=20Kuzn=C3=ADk?= Date: Wed, 1 Sep 2021 16:14:43 +0100 Subject: [PATCH] ITS#9632 Fix lloadd monitor tests to honour BASEPORT --- tests/data/lloadd/monitor.ldif | 6 +++--- tests/data/lloadd/test007-monitor.ldif | 10 +++++----- tests/scripts/lloadd/test004-monitor | 5 ++++- tests/scripts/lloadd/test007-coherence | 5 ++++- 4 files changed, 16 insertions(+), 10 deletions(-) diff --git a/tests/data/lloadd/monitor.ldif b/tests/data/lloadd/monitor.ldif index 9650285df8..0811d22a3c 100644 --- a/tests/data/lloadd/monitor.ldif +++ b/tests/data/lloadd/monitor.ldif @@ -67,7 +67,7 @@ objectClass: monitorContainer dn: cn=backend,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Monit or objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9012/ +olmServerURI: @URI2@ olmActiveConnections: 4 olmPendingConnections: 0 olmPendingOps: 0 @@ -153,7 +153,7 @@ objectClass: monitorContainer dn: cn=backend,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Monit or objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9012/ +olmServerURI: @URI2@ olmActiveConnections: 4 olmPendingConnections: 0 olmPendingOps: 0 @@ -204,7 +204,7 @@ olmFailedOps: 0 dn: cn=server 2,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Moni tor objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9013/ +olmServerURI: @URI3@ olmActiveConnections: 9 olmPendingConnections: 0 olmPendingOps: 0 diff --git a/tests/data/lloadd/test007-monitor.ldif b/tests/data/lloadd/test007-monitor.ldif index aff5697a19..52c2c966e9 100644 --- a/tests/data/lloadd/test007-monitor.ldif +++ b/tests/data/lloadd/test007-monitor.ldif @@ -35,7 +35,7 @@ objectClass: monitorContainer dn: cn=backend,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Monit or objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9012/ +olmServerURI: @URI2@ olmActiveConnections: 4 olmPendingConnections: 0 olmPendingOps: 0 @@ -121,7 +121,7 @@ objectClass: monitorContainer dn: cn=backend,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Monit or objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9012/ +olmServerURI: @URI2@ olmActiveConnections: 4 olmPendingConnections: 0 olmPendingOps: 0 @@ -172,7 +172,7 @@ olmFailedOps: 0 dn: cn=server 2,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Moni tor objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9013/ +olmServerURI: @URI3@ olmActiveConnections: 9 olmPendingConnections: 0 olmPendingOps: 0 @@ -308,7 +308,7 @@ objectClass: monitorContainer dn: cn=backend,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Monit or objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9012/ +olmServerURI: @URI2@ olmActiveConnections: 4 olmPendingConnections: 0 olmPendingOps: 0 @@ -359,7 +359,7 @@ olmFailedOps: 0 dn: cn=server 2,cn=first,cn=Backend Tiers,cn=Load Balancer,cn=Backends,cn=Moni tor objectClass: olmBalancerServer -olmServerURI: ldap://localhost:9013/ +olmServerURI: @URI3@ olmActiveConnections: 9 olmPendingConnections: 0 olmPendingOps: 0 diff --git a/tests/scripts/lloadd/test004-monitor b/tests/scripts/lloadd/test004-monitor index bc6d33ad95..8d89234c9d 100755 --- a/tests/scripts/lloadd/test004-monitor +++ b/tests/scripts/lloadd/test004-monitor @@ -345,7 +345,10 @@ LDIF=$DATADIR/lloadd/monitor.ldif echo "Filtering ldapsearch results..." $LDIFFILTER -s e < $SEARCHOUT > $SEARCHFLT echo "Filtering original ldif used to create database..." -$LDIFFILTER -s e < $LDIF > $LDIFFLT +$LDIFFILTER -s e < $LDIF | sed \ + -e "s|@URI2@|$URI2|g" \ + -e "s|@URI3@|$URI3|g" \ + > $LDIFFLT echo "Comparing filter output..." $CMP $SEARCHFLT $LDIFFLT > $CMPOUT diff --git a/tests/scripts/lloadd/test007-coherence b/tests/scripts/lloadd/test007-coherence index 4a42085e12..6dff7ed71f 100755 --- a/tests/scripts/lloadd/test007-coherence +++ b/tests/scripts/lloadd/test007-coherence @@ -485,7 +485,10 @@ LDIF=$DATADIR/lloadd/test007-monitor.ldif echo "Filtering ldapsearch results..." $LDIFFILTER < $SEARCHOUT > $SEARCHFLT echo "Filtering original ldif used to create database..." -$LDIFFILTER < $LDIF > $LDIFFLT +$LDIFFILTER < $LDIF | sed \ + -e "s|@URI2@|$URI2|g" \ + -e "s|@URI3@|$URI3|g" \ + > $LDIFFLT echo "Comparing filter output..." $CMP $SEARCHFLT $LDIFFLT > $CMPOUT -- 2.47.3