dep-curl/tests
Stefan Eissing c8df3defd9
lib: new easy option string storage
Change the storage of easy handle option strings from an array sized for
all possible options to a hash set to reduce memory footprint.

Give the hash set initially room for 4 strings, with first allocation
happening when it goes beyond that. Measurements without test suite
and a forced fail on growing the set gives:

Size Result
2    1261 tests out of 1951 reported OK: 64%
4    1792 tests out of 1951 reported OK: 91%
8    1944 tests out of 1951 reported OK: 99%
16   1949 tests out of 1951 reported OK: 99%
32   single fail of 3211, unit test for u8_strset

Add u8_strset that keeps the tuples (uint8_t id, char *str)
and allows set/unset by `id`. Add that as data->set.strings.

Define MACROS
* CURL_EASY_STR(data, id) for access
* CURL_EASY_STR_SET(data, id, s) for setting, making a copy
* CURL_EASY_STR_SETN(data, id, s) for setting, no copy
* CURL_EASY_STR_CLEAR(data, id) for unsetting
* CURL_EASY_STR_CLEAR0(data, id) for unsetting and zero-ing value

Add `data->set.str_copypostfields` to handle former `STRING_COPYPOSTFIELDS`
string that was not always a string and could carry NUL bytes.

Add unit tests to test3211.

Closes #22628
2026-08-21 09:36:07 +02:00
..
certs GHA/windows: install MSYS2 Perl manually on Windows 2025 runner 2026-08-14 16:15:18 +02:00
cmake tidy-up: C and CI 2026-08-12 15:42:54 +02:00
data lib: new easy option string storage 2026-08-21 09:36:07 +02:00
http test_07_upload: skip tests if nghttpx lacks QUIC 2026-08-20 07:41:56 -07:00
libtest header api: add guards 2026-08-12 21:56:48 +02:00
server curlx_inet_ntop: return CURLcode, drop setting errno 2026-08-17 18:41:31 +02:00
tunit tidy-up: use more static, sizeof(), char[], double-const 2026-07-28 13:53:11 +02:00
unit lib: new easy option string storage 2026-08-21 09:36:07 +02:00
.gitignore build: stop building and installing runtests.1 and testcurl.1 2026-04-28 09:07:27 +02:00
allversions.pm tidy-up: syntax and code nits 2026-06-26 15:45:24 +02:00
appveyor.pm perl: switch from backticks to qx() 2026-06-14 14:25:02 +02:00
azure.pm perl: switch from backticks to qx() 2026-06-14 14:25:02 +02:00
CMakeLists.txt cmake: fix not to build tunits when BUILD_CURL_EXE=OFF 2026-06-26 21:12:35 +02:00
config.in
configurehelp.pm.in build: use configurehelp.pm.in with autotools and cmake 2024-09-21 12:21:14 +02:00
devtest.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
dictserver.py tests: target Python 3.8 as the minimum Python version 2026-07-28 08:52:01 -07:00
directories.pm tidy-up: miscellaneous 2025-12-12 04:18:48 +01:00
ech_combos.py tests: change whitespace and comments in Python test code 2026-07-28 08:52:01 -07:00
ech_tests.sh scripts: use end-of-options marker in cd, mkdir, mv, sha256sum commands 2026-06-25 11:32:36 +02:00
ftpserver.pl tidy-up: comments, messages, formatting 2026-07-30 11:26:22 +02:00
getpart.pm tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
globalconfig.pm tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
http-server.pl tidy-up: miscellaneous 2026-06-01 22:33:57 +02:00
http2-server.pl tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
http3-server.pl tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
Makefile.am tidy-up: syntax and code nits 2026-06-26 15:45:24 +02:00
memanalyze.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
memanalyzer.pm tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
negtelnetserver.py tidy-up: comments, messages, formatting 2026-07-30 11:26:22 +02:00
nghttpx.conf
pathhelp.pm tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
processhelp.pm tidy-up: miscellaneous 2026-06-14 20:10:28 +02:00
requirements.txt GHA: bump GitHub Actions and pips 2026-08-02 00:02:10 +02:00
rtspserver.pl tidy-up: miscellaneous 2026-06-01 22:33:57 +02:00
runner.pm runtests: allow comments in setenv section, merge sections in test433 2026-07-26 16:43:18 +02:00
runtests.pl runtests: divide minimum required tests by subsets 2026-08-18 15:45:16 +02:00
secureserver.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
serverhelp.pm TLS: drop support for TLS-SRP 2026-07-04 12:20:20 +02:00
servers.pm tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
smbserver.py tests: use simpler constructions in Python code 2026-07-28 08:52:01 -07:00
sshhelp.pm perl: switch from backticks to qx() 2026-06-14 14:25:02 +02:00
sshserver.pl sshserver.pl: bump an sshd config to use its modern name 2026-08-02 11:47:46 +02:00
test745.pl perl: || die -> or die 2026-06-16 00:41:29 +02:00
test971.pl perl: || die -> or die 2026-06-16 00:41:29 +02:00
test1119.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
test1135.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
test1139.pl tidy-up: docs, comments, typos, whitespace 2026-06-26 11:36:09 +02:00
test1140.pl tidy-up: docs, comments, typos, whitespace 2026-06-26 11:36:09 +02:00
test1165.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
test1167.pl perl: open... || -> open... or (cont.) 2026-06-16 19:11:15 +02:00
test1173.pl perl: open... || -> open... or (cont.) 2026-06-16 19:11:15 +02:00
test1175.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
test1177.pl TLS: drop support for TLS-SRP 2026-07-04 12:20:20 +02:00
test1222.pl perl: open... || -> open... or (cont.) 2026-06-16 19:11:15 +02:00
test1275.pl scripts: replace/extend -- with --end-of-options in git commands 2026-07-22 21:14:52 +02:00
test1276.pl tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
test1477.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
test1486.pl tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
test1488.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
test1544.pl tidy-up: add spaces around equal operators where missing 2026-06-11 19:52:01 +02:00
test1707.pl tidy-up: syntax and code nits 2026-06-26 15:45:24 +02:00
testcurl.pl tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
testutil.pm tidy-up: fix Perl syntax and formatting nits 2026-07-23 12:56:18 +02:00
tftpserver.pl tidy-up: miscellaneous 2026-06-01 22:33:57 +02:00
util.py tests: use simpler constructions in Python code 2026-07-28 08:52:01 -07:00
valgrind.pm perl: open... || -> open... or (cont.) 2026-06-16 19:11:15 +02:00
valgrind.supp spnego: block NTLM fallback in SPNEGO negotiation 2026-07-27 17:28:52 -04:00