1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-21 15:48:49 -05:00

test suite: use test case specific netrc file names

This commit is contained in:
Yang Tse 2011-09-05 12:39:50 +02:00
parent d52f3eb598
commit eb44ac0138
9 changed files with 17 additions and 14 deletions

View File

@ -37,9 +37,9 @@ ftp
FTP (optional .netrc; no user/pass) dir list PASV
</name>
<command>
--netrc-optional --netrc-file log/netrc ftp://%HOSTIP:%FTPPORT/
--netrc-optional --netrc-file log/netrc130 ftp://%HOSTIP:%FTPPORT/
</command>
<file name="log/netrc" >
<file name="log/netrc130" >
# the following two lines were created while testing curl
machine %HOSTIP login user1 password passwd1
machine %HOSTIP login user2 password passwd2

View File

@ -21,7 +21,7 @@ netrc parsing unit tests
<tool>
unit1304
</tool>
<file name="log/netrc">
<file name="log/netrc1304">
machine example.com login admin password passwd
machine curl.example.com login none password none
</file>

View File

@ -38,9 +38,9 @@ ftp
FTP (optional .netrc; user/no pass) dir list PASV
</name>
<command>
--netrc-optional --netrc-file log/netrc ftp://user2@%HOSTIP:%FTPPORT/
--netrc-optional --netrc-file log/netrc131 ftp://user2@%HOSTIP:%FTPPORT/
</command>
<file name="log/netrc" >
<file name="log/netrc131" >
# the following two lines were created while testing curl
machine %HOSTIP login user1 password passwd1
machine %HOSTIP login user2 password passwd2

View File

@ -37,9 +37,9 @@ ftp
FTP (optional .netrc; user/passwd supplied) dir list PASV
</name>
<command>
--netrc-optional --netrc-file log/netrc ftp://mary:mark@%HOSTIP:%FTPPORT/
--netrc-optional --netrc-file log/netrc132 ftp://mary:mark@%HOSTIP:%FTPPORT/
</command>
<file name="log/netrc" >
<file name="log/netrc132" >
# the following two lines were created while testing curl
machine %HOSTIP login user1 password passwd1
machine %HOSTIP login user2 password passwd2

View File

@ -37,9 +37,9 @@ ftp
FTP (compulsory .netrc; ignored user/passwd) dir list PASV
</name>
<command>
-n --netrc-file log/netrc ftp://mary:mark@%HOSTIP:%FTPPORT/
-n --netrc-file log/netrc133 ftp://mary:mark@%HOSTIP:%FTPPORT/
</command>
<file name="log/netrc" >
<file name="log/netrc133" >
# the following two lines were created while testing curl
machine %HOSTIP login user1 password passwd1
machine %HOSTIP login user2 password passwd2

View File

@ -37,9 +37,9 @@ ftp
FTP (optional .netrc; programmatic user/passwd) dir list PASV
</name>
<command>
--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/
</command>
<file name="log/netrc" >
<file name="log/netrc134" >
# the following two lines were created while testing curl
machine %HOSTIP login user1 password passwd1
machine %HOSTIP login user2 password passwd2

View File

@ -71,11 +71,11 @@ http
HTTP Location: following with --netrc-optional
</name>
<command>
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
</command>
# netrc auth for two out of three sites:
<file name="log/netrc">
<file name="log/netrc257">
machine supersite.com login user1 password passwd1
machine anotherone.com login user2 password passwd2
</file>

View File

@ -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
}

View File

@ -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));
/*