cURL / Mailing Lists / curl-library / Single Mail

curl-library

[PATCH] tests 2032, 2033: Don't hardcode port in expected output

From: Tor Arntsen <kspt.tor_at_gmail.com>
Date: Thu, 15 Aug 2013 10:06:24 +0200

---
(The full patch is in the attachment, as I have to post via gmail for
this there'll be line wrapping going on and corrupt the patch. So the
below chunk is for illustration.)
Ref. http://curl.haxx.se/dev/log.cgi?id=20130815070159-21913#TESTDONE
which fails because on that host I have to set the -b<port> option to
runtests.pl because the default test port 8990 is occupied already
(some service running). Some testing indicated that for HTTP tests
only test 2032 and 2033 are affected by hardcoded ports in the
'expected output' comparison. Not sure if this is how it's supposed to
be done, but using %HTTPPORT in the tests does fix the specific
problem for me.
-Tor
 tests/data/test2032 |    8 ++++----
 tests/data/test2033 |    8 ++++----
 2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/tests/data/test2032 b/tests/data/test2032
index 02aca81..128deab 100644
--- a/tests/data/test2032
+++ b/tests/data/test2032
@@ -123,22 +123,22 @@ chkhostname curlhost
 <protocol>
 GET /20320100 HTTP/1.1
 Authorization: Basic dGVzdHVzZXI6dGVzdHBhc3M=
-Host: 127.0.0.1:8990
+Host: 127.0.0.1:%HTTPPORT
 Accept: */*
 GET /20320100 HTTP/1.1
 Authorization: Basic dGVzdHVzZXI6dGVzdHBhc3M=
-Host: 127.0.0.1:8990
+Host: 127.0.0.1:%HTTPPORT
 Accept: */*
...


-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html

Received on 2013-08-15