From 3f807e104572b38143a1015be57d875088ceaebb Mon Sep 17 00:00:00 2001 From: Alexander Barton Date: Thu, 17 Apr 2014 23:57:38 +0200 Subject: Test suite: Don't use DNS lookups Different operating systems do behave quite differently when doing DNS lookups, for example "127.0.0.1" sometimes resolves to "localhost" and sometimes to "localhost.localdomain" (for example OpenBSD). And other systems resolve "localhost" to the real host name (for example Cygwin). So not using DNS at all makes the test site much more portable. --- src/testsuite/whois-test.e | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/testsuite/whois-test.e') diff --git a/src/testsuite/whois-test.e b/src/testsuite/whois-test.e index 16b1184b..44eee668 100644 --- a/src/testsuite/whois-test.e +++ b/src/testsuite/whois-test.e @@ -1,7 +1,7 @@ # ngIRCd test suite # WHOIS test -spawn telnet localhost 6789 +spawn telnet 127.0.0.1 6789 expect { timeout { exit 1 } "Connected" @@ -17,7 +17,7 @@ expect { send "whois nick\r" expect { timeout { exit 1 } - "311 nick nick ~user localhost* \* :Real Name\r" + "311 nick nick ~user 127.0.0.1 \* :Real Name\r" } expect { timeout { exit 1 } @@ -27,25 +27,25 @@ expect { send "whois *\r" expect { timeout { exit 1 } - "311 nick nick ~user localhost* \* :Real Name\r" + "311 nick nick ~user 127.0.0.1* \* :Real Name\r" } send "whois n*\r" expect { timeout { exit 1 } - "311 nick nick ~user localhost* \* :Real Name\r" + "311 nick nick ~user 127.0.0.1* \* :Real Name\r" } send "whois ?ick\r" expect { timeout { exit 1 } - "311 nick nick ~user localhost* \* :Real Name\r" + "311 nick nick ~user 127.0.0.1* \* :Real Name\r" } send "whois ????,n?*k\r" expect { timeout { exit 1 } - "311 nick nick ~user localhost* \* :Real Name\r" + "311 nick nick ~user 127.0.0.1* \* :Real Name\r" } send "whois unknown\r" @@ -61,7 +61,7 @@ expect { send "whois ngircd.test.server2 nick\r" expect { timeout { exit 1 } - ":ngircd.test.server2 311 nick nick ~user localhost* \* :Real Name\r" + ":ngircd.test.server2 311 nick nick ~user 127.0.0.1* \* :Real Name\r" } send "whois nosuchserver unknown\r" -- cgit 1.4.1