summaryrefslogtreecommitdiffstats
path: root/net/tools/testserver
Commit message (Collapse)AuthorAgeFilesLines
* The Python test server now ignores querystrings params when serving local files.finnur@chromium.org2009-10-021-2/+8
| | | | | | | | | | | | | | | | I'm having no luck getting the try bots to recognize this change to the python file, so I am separating my already LG'ed changelist (http://codereview.chromium.org/246066) into two (this part and a followup patch) in the hopes that my tests (next CL) will succeed. I fixed our python test server to serve files even though there is a querystring in the url (the server basically just ignores the querystring). This is needed in my next cl because the html we serve has js that acts on data in the querystring. Also made it have the right content-header when serving xml files (text/html). TBR=aa BUG=None TEST=None Review URL: http://codereview.chromium.org/242120 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27862 0039d316-1c4b-4281-b951-d872f2087c98
* Add the ability to not send cookies or send user name/password.levin@chromium.org2009-08-261-0/+21
| | | | | | | | | | | Added unit tests for the above functionality plus the do not save cookies functionality. BUG=http://crbug.com/10961 TEST=Added unit tests for this. Also, this isn't yet called from the rest of the code. Review URL: http://codereview.chromium.org/173206 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24412 0039d316-1c4b-4281-b951-d872f2087c98
* Speed up net_unittests a bit by re-using launched test server.phajdan.jr@chromium.org2009-08-141-2/+23
| | | | | | | | | | | | | | On POSIX it makes the server fork a separate process for each request for better test isolation. Starting with just few tests to limit impact of an eventual breakage. The results are promising. TEST=none BUG=none Review URL: http://codereview.chromium.org/164522 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23481 0039d316-1c4b-4281-b951-d872f2087c98
* Add support to URLRequest for deferring redirects.darin@chromium.org2009-07-231-0/+4
| | | | | | | | | | | | | | | | | | | | I chose to add an out parameter to OnReceivedRedirect because it allows for the default behavior to remain the same. I considered adding a ContinueAfterRedirect method that all OnReceivedRedirect implementations would need to call, but this caused one annoying problem: In the case of a ChromePlugin, it is possible for the URLRequest to get deleted inside the handler for the redirect. This would make it hard to subsequently call a method on the URLRequest since I would need to have a way to determine if the URLRequest had been deleted. TEST=covered by unit tests BUG=16413,6442 R=eroman,wtc Review URL: http://codereview.chromium.org/155897 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21417 0039d316-1c4b-4281-b951-d872f2087c98
* Change timeout settings in CacheTest tohuanr@chromium.org2009-05-231-2/+2
| | | | | | | | make it run faster. Review URL: http://codereview.chromium.org/115678 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16833 0039d316-1c4b-4281-b951-d872f2087c98
* Fix testserver to return a correct MIME-type header.ericroman@google.com2009-05-071-1/+2
| | | | | | | | | | | | Originally, testserver was sending "Content-type: text/html" header regardless of a file extension, due to a bug in TestPageHandler.GetMIMETypeFromName. Patch by Yuta Kitamura <yutak@google.com>. Original code review: <http://codereview.chromium.org/100357> Review URL: http://codereview.chromium.org/115058 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15510 0039d316-1c4b-4281-b951-d872f2087c98
* Scrape search definitions from forms that have onsubmit handlers. The ↵ben@chromium.org2009-04-101-1/+6
| | | | | | | | | | | | | | | | scraping is done after submit events are handled by the page DOM so doing this is safe. Adds test infrastructure for determining that scraping occurs on submit: - allow testserver to be configured to serve pages from / on the server - provide a ui test util that navigates and waits for N subsequent redirections/navigations before returning control to the test to handle automated submission Eric, please review the test server changes. Scott, please look over everything else. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=13444 Review URL: http://codereview.chromium.org/62145 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13491 0039d316-1c4b-4281-b951-d872f2087c98
* revert until I can figure out why the tests are hangingben@chromium.org2009-04-091-6/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13448 0039d316-1c4b-4281-b951-d872f2087c98
* Scrape search definitions from forms that have onsubmit handlers. The ↵ben@chromium.org2009-04-091-1/+6
| | | | | | | | | | | | | | scraping is done after submit events are handled by the page DOM so doing this is safe. Adds test infrastructure for determining that scraping occurs on submit: - allow testserver to be configured to serve pages from / on the server - provide a ui test util that navigates and waits for N subsequent redirections/navigations before returning control to the test to handle automated submission Eric, please review the test server changes. Scott, please look over everything else. Review URL: http://codereview.chromium.org/62145 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13444 0039d316-1c4b-4281-b951-d872f2087c98
* Respect cookies set in a 401 responses when restarting the http transaction.ericroman@google.com2009-03-271-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | There are two parts to this change: (1) rebuild the request cookies before each transaction restart for authentication (2) notify the URLRequestHttpJob of header completion before *each* transaction restart for authentication By "each transaction" I mean the automatic restarts that don't require user input, such as: - replying to the first step of NTLM - selecting identity embedded in URL - selecting identity in auth-cache Needing to notify URLRequestHttpJob for these intermediate restarts is a consequence of cookie store management being done outside of HttpNetworkTransaction. After updating the cookie store, URLRequestHttpJob now tests |HttpTransaction::IsReadyToRestartForAuth()| to check whether the notification was informational or an identity is actually needed. R=wtc BUG=6450 Review URL: http://codereview.chromium.org/51004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12635 0039d316-1c4b-4281-b951-d872f2087c98
* Slight code change to make some global variables const.maruel@google.com2009-03-101-22/+46
| | | | | | | Fix >80 cols lines. Review URL: http://codereview.chromium.org/42013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11342 0039d316-1c4b-4281-b951-d872f2087c98
* fixes for python 2.6 warnings in the testserver.thomasvl@chromium.org2009-03-061-7/+13
| | | | | | | BUG=8300 Review URL: http://codereview.chromium.org/40235 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11142 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes CRLF and trailing white spaces.maruel@chromium.org2009-03-051-7/+7
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10982 0039d316-1c4b-4281-b951-d872f2087c98
* Add a unit test for ERR_UNEXPECTED_SERVER_AUTH.wtc@chromium.org2009-02-141-0/+16
| | | | | | | | | | | | Remove the obsolete change to URLRequestHttpJob::IsRedirectResponse, which was accidentally checked in. R=eroman BUG=7338 Review URL: http://codereview.chromium.org/20279 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9816 0039d316-1c4b-4281-b951-d872f2087c98
* Sanitize proxy response codes to CONNECT requests. Forwtc@chromium.org2009-02-111-2/+40
| | | | | | | | | | | | | | | | | | anything other than 200 (success) or 400-599 (error), we rewrite the response code as 500 (internal server error) to prevent any special handling of the proxy's response to CONNECT by mistake. Add a new error code ERR_UNEXPECTED_SERVER_AUTH for a 401 response to a CONNECT request. Fix nits reported by cpplint.py. R=darin,eroman BUG=7338 Review URL: http://codereview.chromium.org/21158 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9549 0039d316-1c4b-4281-b951-d872f2087c98
* Make test server to store files by sending POST /writefile/<filename> HTTP ↵stoyan@chromium.org2009-01-301-1/+39
| | | | | | | | request. Review URL: http://codereview.chromium.org/19476 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8965 0039d316-1c4b-4281-b951-d872f2087c98
* Add FTP unit test in preparation for portable FTP implementation.erikkay@google.com2009-01-081-24/+73
| | | | | | | | | | | | Clean up test server code. Originally from issue 12939, written by Ibrar Ahmed (ibrar.ahmed@gmail.com) (take 2) Review URL: http://codereview.chromium.org/17040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7755 0039d316-1c4b-4281-b951-d872f2087c98
* Fix the test server to be smarter about when tonsylvain@chromium.org2008-12-301-98/+58
| | | | | | | | | | | | | | handle a command or not. This is to fix this problem: Adding a new command called "slowread" will not work if added after "slow", because the handler for "slow" handles all the commands that STARTS with slow, instead of slow[/?$] Review URL: http://codereview.chromium.org/17009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7515 0039d316-1c4b-4281-b951-d872f2087c98
* Add FTP unit test in preparation for portable FTP implementation.erikkay@google.com2008-12-301-24/+73
| | | | | | | | | | | Clean up test server code. Originally from issue 12939, written by Ibrar Ahmed (ibrar.ahmed@gmail.com) Review URL: http://codereview.chromium.org/16490 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7508 0039d316-1c4b-4281-b951-d872f2087c98
* Don't send Content-Type when redirecting from a POST.ericroman@google.com2008-11-151-5/+8
| | | | | | | | http://code.google.com/p/chromium/issues/detail?id=843 Review URL: http://codereview.chromium.org/10873 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5532 0039d316-1c4b-4281-b951-d872f2087c98
* Use a more compact license header in source files.license.bot2008-08-241-28/+4
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1287 0039d316-1c4b-4281-b951-d872f2087c98
* Add net to the repository.initial.commit2008-07-263-0/+943
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14 0039d316-1c4b-4281-b951-d872f2087c98