[red-knot] mdtest suite: formatting and cleanup (#13806)

Minor cleanup and consistent formatting of the Markdown-based tests.

- Removed lots of unnecessary `a`, `b`, `c`, … variables.
- Moved test assertions (`# revealed:` comments) closer to the tested
object.
- Always separate `# revealed` and `# error` comments from the code by
two spaces, according to the discussion
[here](https://github.com/astral-sh/ruff/pull/13746/files#r1799385758).
This trades readability for consistency in some cases.
- Fixed some headings
This commit is contained in:
David Peter
2024-10-18 11:07:53 +02:00
committed by GitHub
parent f80528fbf2
commit c2f7c39987
44 changed files with 289 additions and 468 deletions

View File

@@ -13,7 +13,7 @@ def f(x: str):
```py path=a.py
def f(): pass
f = 1 # error: "Implicit shadowing of function `f`; annotate to make it explicit if this is intentional"
f = 1 # error: "Implicit shadowing of function `f`; annotate to make it explicit if this is intentional"
```
## Explicit shadowing