mirror of
https://github.com/curl/curl.git
synced 2026-08-24 15:33:37 +03:00
test1646: netrc parsing without user match but user in URL
Follow-up to 4ae1d7cc26
This commit is contained in:
parent
4ae1d7cc26
commit
7ca5f939c8
2 changed files with 46 additions and 0 deletions
45
tests/data/test1646
Normal file
45
tests/data/test1646
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
<?xml version="1.0" encoding="US-ASCII"?>
|
||||
<testcase>
|
||||
<info>
|
||||
<keywords>
|
||||
netrc
|
||||
</keywords>
|
||||
</info>
|
||||
|
||||
<reply>
|
||||
<data>
|
||||
HTTP/1.1 200 OK
|
||||
Content-Length: 6
|
||||
|
||||
12345
|
||||
</data>
|
||||
</reply>
|
||||
|
||||
# Client-side
|
||||
<client>
|
||||
<server>
|
||||
http
|
||||
</server>
|
||||
<name>
|
||||
netrc parsing without user match but user in URL
|
||||
</name>
|
||||
<command>
|
||||
--netrc --netrc-file %LOGDIR/netrc%TESTNUMBER http://alice@example.com:%HTTPPORT/%TESTNUMBER --resolve example.com:%HTTPPORT:%HOSTIP
|
||||
</command>
|
||||
<file name="%LOGDIR/netrc%TESTNUMBER" >
|
||||
machine example.com login bob password sekret
|
||||
</file>
|
||||
</client>
|
||||
|
||||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<protocol crlf="headers">
|
||||
GET /%TESTNUMBER HTTP/1.1
|
||||
Host: example.com:%HTTPPORT
|
||||
Authorization: Basic %b64[alice:]b64%
|
||||
User-Agent: curl/%VERSION
|
||||
Accept: */*
|
||||
|
||||
</protocol>
|
||||
</verify>
|
||||
</testcase>
|
||||
Loading…
Add table
Add a link
Reference in a new issue