hostip: bad CURLOPT_RESOLVE syntax now returns error

Added test 3019
Fixes #7170
Closes #7174
This commit is contained in:
Alexis Vachette 2021-06-02 14:12:10 +02:00 committed by Daniel Stenberg
parent 002f976cdc
commit cb39b4b7c4
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
3 changed files with 41 additions and 3 deletions

36
tests/data/test3019 Normal file
View file

@ -0,0 +1,36 @@
<testcase>
<info>
<keywords>
HTTP
HTTP GET
--resolve
</keywords>
</info>
#
# Server-side
<reply>
</reply>
#
# Client-side
<client>
<server>
http
</server>
<name>
HTTP with invalid --resolve syntax
</name>
<command>
--resolve %HTTPPORT:example.com:%HOSTIP http://example.com:%HTTPPORT/%TESTNUMBER
</command>
</client>
#
# Verify data after the test has been "shot"
<verify>
<errorcode>
49
</errorcode>
</verify>
</testcase>