tooling: Fixes/cleanups/tests for rst_check.py#17589
Conversation
e219127 to
7ddb4e4
Compare
Signed-off-by: Ryan Northey <ryan@synca.io>
7ddb4e4 to
45dfc2c
Compare
|
coverage is here https://storage.googleapis.com/envoy-pr/17589/tooling/index.html |
rst_checks.pyrst_check.py
alyssawilk
left a comment
There was a problem hiding this comment.
Nice catch, thanks for generalizing
| ("new_line_re", "VERSION_HISTORY_NEW_LINE_REGEX"), | ||
| ("punctuation_re", "REF_WITH_PUNCTUATION_REGEX"), | ||
| ("section_name_re", "VERSION_HISTORY_SECTION_NAME"))) | ||
| def test_rst_check_current_version_regexes(patches, constant): |
There was a problem hiding this comment.
either in this Pr or a follow-up can you comment up these tests a bit? when I broke one the error messages were pretty confusing and the code was pretty hard to read for someone with low python skills.
There was a problem hiding this comment.
yep happy to add some comments in a follow up - mostly i havent because the tests fairly systematically test methods/functions and follow pytest/mock conventions
testing can be done with, eg:
bazel run //tools/docs:pytest_rst_checkif something breaks breakpoint() can be a lifesaver with the tests
There was a problem hiding this comment.
...well that is not entirely accurate - i added the patches fixture - i should probs document how the tests work, and how to quickly debug them better more generally i think
There was a problem hiding this comment.
actually there is this here https://github.com/envoyproxy/envoy/blob/main/tools/README.md - could probs do with some updating
…bridge-stream * upstream/main: stream info: add upstream connection id (envoyproxy#17512) runtime: removing require_ocsp_response_for_must_staple_certs (envoyproxy#17541) tooling: Fixes/cleanups/tests for `rst_checks.py` (envoyproxy#17589) Add a new HappyEyeballsConnectionImpl class (envoyproxy#17371) hcm/listener_manager: remove deprecated v2 config handling. (envoyproxy#17586) tools: simplify bazel deps query (envoyproxy#17599) tooling: Move tempdir/cleanup to base runner class (envoyproxy#17590) tools: fix missing format strings (envoyproxy#17600) tooling: Add `@envoy` prefix in `envoy_py_` macros (envoyproxy#17588) stream info: add attempt count for HTTP requests and TCP proxy (envoyproxy#17583) Signed-off-by: Garrett Bourg <bourg@squareup.com>
Signed-off-by: Ryan Northey <ryan@synca.io>
Signed-off-by: Ryan Northey ryan@synca.io
Commit Message: tooling: Fixes/cleanups/tests for
rst_checks.pyAdditional Description:
Cleanups for
rst_check.pyRisk Level:
Testing:
Docs Changes:
Release Notes:
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Deprecated:]
[Optional API Considerations:]