]> granicus.if.org Git - curl/commitdiff
test suite: use test case specific netrc file names
authorYang Tse <yangsita@gmail.com>
Mon, 5 Sep 2011 10:39:50 +0000 (12:39 +0200)
committerYang Tse <yangsita@gmail.com>
Mon, 5 Sep 2011 10:39:50 +0000 (12:39 +0200)
tests/data/test130
tests/data/test1304
tests/data/test131
tests/data/test132
tests/data/test133
tests/data/test134
tests/data/test257
tests/runtests.pl
tests/unit/unit1304.c

index fbcf5251b458c58c7299eef8d0d2679a97cb5f7b..dcc46fc8f559c82c04346e53677064276457dcf8 100644 (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
index f438a6929c6845d971c7bef69e64b561fbf05ea5..d518de9e4cb31ca8b5a30c3f2ec4d780d0f587e3 100644 (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>
index ad7f9e22aa95341fd120c8d0dc2bf5d991ee5ee1..86501c627f62f17ea75ea8ea0ce1ccb3adafe0a7 100644 (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
index 8d9e3ed60715cfae7efda2aa4e8b6d29b8ac9f5b..ed96953bb36f68abdf026ac2e5b737303c885e5e 100644 (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
index a15cfc3718e2b96513a77f46b149bd34a73fee11..085092d01bf2249aa64e0b96dfd48db3dc9e2319 100644 (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
index 83035849eafddbc0c3b5e9c792cabbd153dd6095..8a3ba62042d73b9e17b8843a5c972870aeeed7ae 100644 (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
index cc3b7f00a3e6bd53bc8fde7605c4cfa3698a0ff3..45642d57173a4eeaa5efe10abb166ee3d03991e7 100644 (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>
index 773e5652a2c42b161951dbcecca73d8960ef06e1..db502396015d08e06f40fab4fe7fbd2c65abbc01 100755 (executable)
@@ -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
         }
index 7b2985c58c553e82bab2b0d5e139c5930d4643c6..8ddd8caee849a522c20d63afb2ba6b31d0ee374d 100644 (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));
 
   /*