tidy-up: miscellaneous

- drop more uses of the word "just". (not enforced here)
- drop some uses of the "will" word.
- "then" -> "than".
- tests/http/testenv/curl.py: fix copy-paste typo in error message.
- pytest: replace `shutdownh` with `shutdown` in test names.
  Spotted by GitHub Code Quality.
- comment typos.
- whitespace and newlines fixes.

Closes #21830
This commit is contained in:
Viktor Szakats 2026-05-28 23:50:52 +02:00
parent 032b15c434
commit d229055549
No known key found for this signature in database
116 changed files with 184 additions and 185 deletions

View file

@ -145,7 +145,7 @@ class TestDownload:
])
r.check_response(http_status=200, count=count)
# should have used at most 2 connections only (test servers allow 100 req/conn)
# it may be just 1 on slow systems where request are answered faster than
# it may be 1 on slow systems where request are answered faster than
# curl can exhaust the capacity or if curl runs with address-sanitizer speed
assert r.total_connects <= 2, "h2 should use fewer connections here"
@ -417,7 +417,7 @@ class TestDownload:
assert r.exit_code == 0, f'{client.dump_logs()}'
# Special client that tests TLS session reuse in parallel transfers
# TODO: just uses a single connection for h2/h3. Not sure how to prevent that
# TODO: uses a single connection for h2/h3. Not sure how to prevent that
@pytest.mark.parametrize("proto", Env.http_protos())
def test_02_26_session_shared_reuse(self, env: Env, proto, httpd, nghttpx):
url = f'https://{env.authority_for(env.domain1, proto)}/data-100k'

View file

@ -100,7 +100,7 @@ class TestErrors:
assert r.stats[0]['http_version'] == '1.1', r.dump_logs()
# On the URL used here, Apache is doing an "unclean" TLS shutdown,
# meaning it sends no shutdown notice and just closes TCP.
# meaning it sends no shutdown notice and closes TCP.
# The HTTP response delivers a body without Content-Length. We expect:
# - http/1.0 to fail since it relies on a clean connection close to
# detect the end of the body

View file

@ -95,7 +95,7 @@ class TestAuth:
if proto == 'h3' and not env.curl_uses_lib('ngtcp2'):
# See <https://github.com/cloudflare/quiche/issues/1573>
pytest.skip("quiche has problems with large requests")
# just large enough that nghttp2 will submit
# large enough that nghttp2 will submit
password = 'x' * (47 * 1024)
fdata = os.path.join(env.gen_dir, 'data-10m')
curl = CurlClient(env=env)

View file

@ -148,7 +148,7 @@ class TestVsFTPD:
@pytest.mark.skipif(condition=not Env.tcpdump(), reason="tcpdump not available")
@pytest.mark.skipif(condition=not Env.curl_is_debug(), reason="needs curl debug")
@pytest.mark.skipif(condition=not Env.curl_is_verbose(), reason="needs curl verbose strings")
def test_30_06_shutdownh_download(self, env: Env, vsftpd: VsFTPD):
def test_30_06_shutdown_download(self, env: Env, vsftpd: VsFTPD):
docname = 'data-1k'
curl = CurlClient(env=env)
count = 1
@ -166,7 +166,7 @@ class TestVsFTPD:
@pytest.mark.skipif(condition=not Env.tcpdump(), reason="tcpdump not available")
@pytest.mark.skipif(condition=not Env.curl_is_debug(), reason="needs curl debug")
@pytest.mark.skipif(condition=not Env.curl_is_verbose(), reason="needs curl verbose strings")
def test_30_07_shutdownh_upload(self, env: Env, vsftpd: VsFTPD):
def test_30_07_shutdown_upload(self, env: Env, vsftpd: VsFTPD):
docname = 'upload-1k'
curl = CurlClient(env=env)
srcfile = os.path.join(env.gen_dir, docname)

View file

@ -153,7 +153,7 @@ class TestVsFTPD:
@pytest.mark.skipif(condition=not Env.tcpdump(), reason="tcpdump not available")
@pytest.mark.skipif(condition=not Env.curl_is_debug(), reason="needs curl debug")
@pytest.mark.skipif(condition=not Env.curl_is_verbose(), reason="needs curl verbose strings")
def test_31_06_shutdownh_download(self, env: Env, vsftpds: VsFTPD):
def test_31_06_shutdown_download(self, env: Env, vsftpds: VsFTPD):
docname = 'data-1k'
curl = CurlClient(env=env)
count = 1
@ -170,7 +170,7 @@ class TestVsFTPD:
@pytest.mark.skipif(condition=not Env.tcpdump(), reason="tcpdump not available")
@pytest.mark.skipif(condition=not Env.curl_is_debug(), reason="needs curl debug")
@pytest.mark.skipif(condition=not Env.curl_is_verbose(), reason="needs curl verbose strings")
def test_31_07_shutdownh_upload(self, env: Env, vsftpds: VsFTPD):
def test_31_07_shutdown_upload(self, env: Env, vsftpds: VsFTPD):
docname = 'upload-1k'
curl = CurlClient(env=env)
srcfile = os.path.join(env.gen_dir, docname)

View file

@ -166,7 +166,7 @@ class TestFtpsVsFTPD:
@pytest.mark.skipif(condition=not Env.tcpdump(), reason="tcpdump not available")
@pytest.mark.skipif(condition=not Env.curl_is_debug(), reason="needs curl debug")
@pytest.mark.skipif(condition=not Env.curl_is_verbose(), reason="needs curl verbose strings")
def test_32_06_shutdownh_download(self, env: Env, vsftpds: VsFTPD):
def test_32_06_shutdown_download(self, env: Env, vsftpds: VsFTPD):
docname = 'data-1k'
curl = CurlClient(env=env)
count = 1
@ -183,7 +183,7 @@ class TestFtpsVsFTPD:
@pytest.mark.skipif(condition=not Env.tcpdump(), reason="tcpdump not available")
@pytest.mark.skipif(condition=not Env.curl_is_debug(), reason="needs curl debug")
@pytest.mark.skipif(condition=not Env.curl_is_verbose(), reason="needs curl verbose strings")
def test_32_07_shutdownh_upload(self, env: Env, vsftpds: VsFTPD):
def test_32_07_shutdown_upload(self, env: Env, vsftpds: VsFTPD):
docname = 'upload-1k'
curl = CurlClient(env=env)
srcfile = os.path.join(env.gen_dir, docname)

View file

@ -285,7 +285,7 @@ class TestH3Proxy:
)
# An HTTP/3 target auto-triggers CONNECT-UDP even without --proxytunnel,
# just as HTTPS targets auto-trigger CONNECT. nghttpx does not support
# as HTTPS targets auto-trigger CONNECT. nghttpx does not support
# CONNECT-UDP so this fails, which confirms auto-CONNECT-UDP is active.
assert r.exit_code != 0, (
"expected failure: h3 target auto-triggers CONNECT-UDP "

View file

@ -1239,7 +1239,7 @@ class CurlClient:
def _perf_collapse(self, perf: PerfProfile, file_err):
if not os.path.exists(perf.file):
raise Exception(f'dtrace output file does not exist: {perf.file}')
raise Exception(f'perf output file does not exist: {perf.file}')
fg_collapse = os.path.join(self._fg_dir, 'stackcollapse-perf.pl')
if not os.path.exists(fg_collapse):
raise Exception(f'FlameGraph script not found: {fg_collapse}')

View file

@ -339,7 +339,7 @@ static int curltest_tweak_handler(request_rec *r)
}
}
else if(!strcmp("id", arg)) {
/* just an id for repeated requests with curl's URL globbing */
/* an id for repeated requests with curl's URL globbing */
request_id = val;
continue;
}
@ -551,7 +551,7 @@ static int curltest_put_handler(request_rec *r)
*s = '\0';
val = s + 1;
if(!strcmp("id", arg)) {
/* just an id for repeated requests with curl's URL globbing */
/* an id for repeated requests with curl's URL globbing */
request_id = val;
continue;
}
@ -748,7 +748,7 @@ static int curltest_sslinfo_handler(request_rec *r)
*s = '\0';
val = s + 1;
if(!strcmp("id", arg)) {
/* just an id for repeated requests with curl's URL globbing */
/* an id for repeated requests with curl's URL globbing */
request_id = val;
continue;
}
@ -862,7 +862,7 @@ static int curltest_limit_handler(request_rec *r)
*s = '\0';
val = s + 1;
if(!strcmp("id", arg)) {
/* just an id for repeated requests with curl's URL globbing */
/* an id for repeated requests with curl's URL globbing */
request_id = val;
continue;
}