aboutsummaryrefslogtreecommitdiff
path: root/tests
AgeCommit message (Collapse)Author
2012-08-07sws: close sockets properlyJoe Mason
Fix a bug where closed sockets (fd -1) were left in the all_sockets list, because of missing parens in a pointer arithmetic expression Reenable the tests that were locking up due to this bug.
2012-08-07Remove debug logs that were accidentally checked inJoe Mason
2012-08-07Use select in sws, which has better cross-platform support than pollJoe Mason
2012-08-07Use cross-platform curlx_nonblock instead of fcntl in swsJoe Mason
2012-08-06Fixed compiler warning - argument is type long.Guenter Knauf
2012-08-06DISABLED: disable the new tests that do NTLMDaniel Stenberg
The tests 2025, 2028 and 2031 don't work for me so I'll have them disabled for now until we solve the problem.
2012-08-03Add tests of auth retriesJoe Mason
2012-08-02Add a polling loop in main to read from more than one socket at once. Add ↵Joe Mason
the O_NONBLOCK and SO_KEEPALIVE flag to all sockets. Note that several loops which used to continue on a return value of 0 (theoretical since 0 would never be returned without O_NONBLOCK) now break on 0 so that they won't continue reading until after poll is called again.
2012-08-02Change return values of get_request, accept_connection and ↵Joe Mason
service_connection to add a return code for non-blocking sockets: now -1 means error or connection finished, 1 means data was read, and 0 means there is no data available now so need to wait for poll (new return value)
2012-08-02Hoist the loop out of get_request, and make sure that it can be reentered ↵Joe Mason
when a request is half-finished. Note the the req struct used to be re-initialized AFTER reading pipeline data, so now that we initialize it from the caller we must be careful not to overwrite the pipeline data. Also we now need to handle the case where the buffer is already full when get_request is called - previously this never happened as it was always called with an empty buffer and looped until done. Now get_request is called in a loop, so the next step is to run the loop on a socket only when poll signals it is readable.
2012-08-02Move blocks of code from the sws main loop into their own functions for ↵Joe Mason
easier refactoring later. The next step will be to call the correct function after a poll, rather than looping unconditionally
2012-08-02Remove the --fork option of sws, since it makes refactoring to use poll more ↵Joe Mason
complicated and should be redundant once we poll
2012-07-22http: print reason phrase from HTTP status line on errorKamil Dudka
Bug: https://bugzilla.redhat.com/676596
2012-07-20test Makefile: only feature 'unit' once in the list of dirsDaniel Stenberg
2012-07-20Fixed CR issue with Win32 version on MSYS.Guenter Knauf
Previous fix didnt work on Linux ...
2012-07-20Fixed CR issue with Win32 version on MSYS.Guenter Knauf
2012-07-20Fixed MSYS <-> Windows path convertion.Guenter Knauf
Replaced the Windows real path from mount hack with a more reliable and simpler hack: the MSYS shell has a builtin pwd which understands a -W option which does convertion to Windows paths. Tested and confirmed that this works on all MSYS versions I have back to a 3 year old one.
2012-07-19Follow-up fix to detect SSL libs with MinGW.Guenter Knauf
1) the check for winssl needs to come before nss check 2) the SSL checks must begin with a new if or else we will never find any SSL lib with MinGW.
2012-07-17Trial to teach runtests.pl about WinSSL.Guenter Knauf
2012-07-17Fixed warning 'uninitialized value in numeric gt'.Guenter Knauf
This is a MSYS/MinGW-only warning; full warning text is: Use of uninitialized value in numeric gt (>) at ../../curl/tests/runtests.pl line 2227.
2012-07-12tests: verify the stricter numeric option parserDaniel Stenberg
Test 1409 and 1410 verifies the stricter numeric option parser introduced the other day in commit f2b6ebed7b.
2012-07-12SWS: use of uninitialized memory fixDaniel Stenberg
I made "connmon" not get initialized properly before use, and I use the big hammer and make sure we always clear the entire struct to avoid any problem like this in the future.
2012-07-12test48: verify that HEAD doesn't close extraDaniel Stenberg
Two commits ago, we fixed a bug where the connction would be closed prematurely after a HEAD. Now I added connection-monitor to test 48 and added a second HEAD and make sure that both are sent over the same connection. This triggered a failure before the bug fix and now works. Will help us avoid a future regression of this kind.
2012-07-12connection-monitor: always log disconnect when enabledDaniel Stenberg
This makes verifying easier and makes us more sure curl closes the connection only at the correct point in time. Adjusted test 206 and 1008 accordingly and updated the docs for it.
2012-07-10test231: fix wrong -C use!Daniel Stenberg
2012-07-09test 46: use different path lengths to get reliable sort orderDaniel Stenberg
Since the order of the cookies is sorted by the length of the paths, having them on the same path length will make the test depend on what order the qsort() implementation will put them. As seen in the windows/msys output posted by Guenter in this posting: http://curl.haxx.se/mail/lib-2012-07/0105.html
2012-07-05tests: use connection-monitor and verify resultsDaniel Stenberg
Test 1008 and 206 don't show the disconnect since it happens when SWS awaits a new request, but 503 does and so the verify section needs that string added.
2012-07-05sws: support <servercmd> for CONNECT requestsDaniel Stenberg
I moved out the servercmd parsing into a its own function called parse_servercmd() and made sure it gets used also when the test number is extracted from CONNECT requests. It turned out sws didn't do that previously!
2012-07-05FILEFORMAT: provided a full description of connection-monitorDaniel Stenberg
2012-07-05lib503: enable verbose to ease debugging thisDaniel Stenberg
2012-07-05sws: add 'connection-monitor' command supportDaniel Stenberg
Using this, the server will output in the protocol log when the connection gets disconnected and thus we will verify correctly in the test cases that the connection doesn't get closed prematurely. This is important for example NTLM to work. Documentation added to FILEFORMAT, test 503 updated to use this.
2012-07-03cookies: change the URL in the cookie jar file headerDaniel Stenberg
2012-07-02testcurl.pl: fix missing semicolonNeil Bowers
2012-07-02testcurl.pl: allow non in-tree c-ares enabled autobuildYang Tse
2012-07-02configure.ac: verify that libmetalink is new enoughYang Tse
Enabling test2017 to test2022.
2012-06-29test2017 to test2022: more metalink testsYang Tse
With this commit, checks done in previous test2017 are now done in test2018. Whole range test2017 to test2022 DISABLED until configure is capable of requiring a new-enough metalink library. Don't try these without mentioned check in place!
2012-06-29test2005 to test2016: improve failure detectionYang Tse
2012-06-28lib582.c: fix conversion warningYang Tse
2012-06-28Metalink: message updatesTatsuhiro Tsujikawa
Print "parsing (...) OK" only when no warnings are generated. If no file is found in Metalink, treat it FAILED. If no digest is provided, print WARNING in parse_metalink(). Also print validating FAILED after download. These changes make tests 2012 to 2016 pass.
2012-06-27tests: add five more Metalink test casesYang Tse
2012-06-27tests: update Metalink message formatYang Tse
2012-06-24test: Added test HTTP receive cookies over IPv6Ghennadi Procopciuc
2012-06-22tests: add another Metalink test caseYang Tse
2012-06-22tests: Enable test2010 and fixed hash valueTatsuhiro Tsujikawa
2012-06-21tests: add six Metalink test casesYang Tse
2012-06-21test 2005: add verification of hash checking outcomeYang Tse
2012-06-21getpart.pm: remove misleading commentYang Tse
2012-06-21tests: Added Metalink test case # 2005Tatsuhiro Tsujikawa
2012-06-20runtests.pl: make it support metalink featureTatsuhiro Tsujikawa
2012-06-20getpart.pm: make test definition section/part parser more robustYang Tse
Test definition section parts which needed to include xml-lingo as contents of that part required that the xml-blurb was written as a single line. Now the xml-data inside the part can be written multiline making it more readable. Tested with <client><file> part which is written to disk before <command> runs.