From eb44ac013832aab80c3ed90292d7b4f25a8a4d75 Mon Sep 17 00:00:00 2001 From: Yang Tse Date: Mon, 5 Sep 2011 12:39:50 +0200 Subject: test suite: use test case specific netrc file names --- tests/data/test130 | 4 ++-- tests/data/test1304 | 2 +- tests/data/test131 | 4 ++-- tests/data/test132 | 4 ++-- tests/data/test133 | 4 ++-- tests/data/test134 | 4 ++-- tests/data/test257 | 4 ++-- tests/runtests.pl | 3 +++ tests/unit/unit1304.c | 2 +- 9 files changed, 17 insertions(+), 14 deletions(-) diff --git a/tests/data/test130 b/tests/data/test130 index fbcf5251b..dcc46fc8f 100644 --- a/tests/data/test130 +++ b/tests/data/test130 @@ -37,9 +37,9 @@ ftp FTP (optional .netrc; no user/pass) dir list PASV ---netrc-optional --netrc-file log/netrc ftp://%HOSTIP:%FTPPORT/ +--netrc-optional --netrc-file log/netrc130 ftp://%HOSTIP:%FTPPORT/ - + # the following two lines were created while testing curl machine %HOSTIP login user1 password passwd1 machine %HOSTIP login user2 password passwd2 diff --git a/tests/data/test1304 b/tests/data/test1304 index f438a6929..d518de9e4 100644 --- a/tests/data/test1304 +++ b/tests/data/test1304 @@ -21,7 +21,7 @@ netrc parsing unit tests unit1304 - + machine example.com login admin password passwd machine curl.example.com login none password none diff --git a/tests/data/test131 b/tests/data/test131 index ad7f9e22a..86501c627 100644 --- a/tests/data/test131 +++ b/tests/data/test131 @@ -38,9 +38,9 @@ ftp FTP (optional .netrc; user/no pass) dir list PASV ---netrc-optional --netrc-file log/netrc ftp://user2@%HOSTIP:%FTPPORT/ +--netrc-optional --netrc-file log/netrc131 ftp://user2@%HOSTIP:%FTPPORT/ - + # the following two lines were created while testing curl machine %HOSTIP login user1 password passwd1 machine %HOSTIP login user2 password passwd2 diff --git a/tests/data/test132 b/tests/data/test132 index 8d9e3ed60..ed96953bb 100644 --- a/tests/data/test132 +++ b/tests/data/test132 @@ -37,9 +37,9 @@ ftp FTP (optional .netrc; user/passwd supplied) dir list PASV ---netrc-optional --netrc-file log/netrc ftp://mary:mark@%HOSTIP:%FTPPORT/ +--netrc-optional --netrc-file log/netrc132 ftp://mary:mark@%HOSTIP:%FTPPORT/ - + # the following two lines were created while testing curl machine %HOSTIP login user1 password passwd1 machine %HOSTIP login user2 password passwd2 diff --git a/tests/data/test133 b/tests/data/test133 index a15cfc371..085092d01 100644 --- a/tests/data/test133 +++ b/tests/data/test133 @@ -37,9 +37,9 @@ ftp FTP (compulsory .netrc; ignored user/passwd) dir list PASV --n --netrc-file log/netrc ftp://mary:mark@%HOSTIP:%FTPPORT/ +-n --netrc-file log/netrc133 ftp://mary:mark@%HOSTIP:%FTPPORT/ - + # the following two lines were created while testing curl machine %HOSTIP login user1 password passwd1 machine %HOSTIP login user2 password passwd2 diff --git a/tests/data/test134 b/tests/data/test134 index 83035849e..8a3ba6204 100644 --- a/tests/data/test134 +++ b/tests/data/test134 @@ -37,9 +37,9 @@ ftp FTP (optional .netrc; programmatic user/passwd) dir list PASV ---netrc-optional --netrc-file log/netrc -u romulus:rhemus ftp://mary:mark@%HOSTIP:%FTPPORT/ +--netrc-optional --netrc-file log/netrc134 -u romulus:rhemus ftp://mary:mark@%HOSTIP:%FTPPORT/ - + # the following two lines were created while testing curl machine %HOSTIP login user1 password passwd1 machine %HOSTIP login user2 password passwd2 diff --git a/tests/data/test257 b/tests/data/test257 index cc3b7f00a..45642d571 100644 --- a/tests/data/test257 +++ b/tests/data/test257 @@ -71,11 +71,11 @@ http HTTP Location: following with --netrc-optional -http://supersite.com/want/257 -L -x http://%HOSTIP:%HTTPPORT --netrc-optional --netrc-file log/netrc +http://supersite.com/want/257 -L -x http://%HOSTIP:%HTTPPORT --netrc-optional --netrc-file log/netrc257 # netrc auth for two out of three sites: - + machine supersite.com login user1 password passwd1 machine anotherone.com login user2 password passwd2 diff --git a/tests/runtests.pl b/tests/runtests.pl index 773e5652a..db5023960 100755 --- a/tests/runtests.pl +++ b/tests/runtests.pl @@ -4280,6 +4280,9 @@ sub displaylogs { if(($log =~ /^file\d+\.txt/) && ($log !~ /^file$testnum\.txt/)) { next; # skip fileNnn.txt of other tests } + if(($log =~ /^netrc\d+/) && ($log !~ /^netrc$testnum/)) { + next; # skip netrcNnn of other tests + } if(($log =~ /^valgrind\d+/) && ($log !~ /^valgrind$testnum(\..*|)$/)) { next; # skip valgrindNnn of other tests } diff --git a/tests/unit/unit1304.c b/tests/unit/unit1304.c index 7b2985c58..8ddd8caee 100644 --- a/tests/unit/unit1304.c +++ b/tests/unit/unit1304.c @@ -41,7 +41,7 @@ static void unit_stop(void) UNITTEST_START int result; - static const char* filename1 = "log/netrc"; + static const char* filename1 = "log/netrc1304"; memcpy(filename, filename1, strlen(filename1)); /* -- cgit v1.2.3