[red-knot] Format mdtest snippets with the latest version of black (#15819)

This commit is contained in:
Alex Waygood 2025-01-29 23:05:43 +00:00 committed by GitHub
parent 15d886a502
commit 3125332ec1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 6 additions and 6 deletions

View File

@ -56,7 +56,7 @@ repos:
.*?invalid(_.+)*_syntax\.md .*?invalid(_.+)*_syntax\.md
)$ )$
additional_dependencies: additional_dependencies:
- black==24.10.0 - black==25.1.0
- repo: https://github.com/crate-ci/typos - repo: https://github.com/crate-ci/typos
rev: v1.29.4 rev: v1.29.4

View File

@ -106,7 +106,7 @@ def union_example(
Literal["B"], Literal["B"],
Literal[True], Literal[True],
None, None,
] ],
): ):
reveal_type(x) # revealed: Unknown | Literal[-1, "A", b"A", b"\x00", b"\x07", 0, 1, "B", "foo", "bar", True] | None reveal_type(x) # revealed: Unknown | Literal[-1, "A", b"A", b"\x00", b"\x07", 0, 1, "B", "foo", "bar", True] | None
``` ```

View File

@ -151,7 +151,7 @@ b = a / 0
```py ```py
""" """
File level suppressions must come before any non-trivia token, File level suppressions must come before any non-trivia token,
including module docstrings. including module docstrings.
""" """
# error: [unused-ignore-comment] "Unused blanket `type: ignore` directive" # error: [unused-ignore-comment] "Unused blanket `type: ignore` directive"

View File

@ -282,7 +282,7 @@ reveal_type(b) # revealed: Unknown
```py ```py
# error: [invalid-assignment] "Not enough values to unpack (expected 2, got 1)" # error: [invalid-assignment] "Not enough values to unpack (expected 2, got 1)"
(a, b) = "\u9E6C" (a, b) = "\u9e6c"
reveal_type(a) # revealed: LiteralString reveal_type(a) # revealed: LiteralString
reveal_type(b) # revealed: Unknown reveal_type(b) # revealed: Unknown
@ -292,7 +292,7 @@ reveal_type(b) # revealed: Unknown
```py ```py
# error: [invalid-assignment] "Not enough values to unpack (expected 2, got 1)" # error: [invalid-assignment] "Not enough values to unpack (expected 2, got 1)"
(a, b) = "\U0010FFFF" (a, b) = "\U0010ffff"
reveal_type(a) # revealed: LiteralString reveal_type(a) # revealed: LiteralString
reveal_type(b) # revealed: Unknown reveal_type(b) # revealed: Unknown
@ -301,7 +301,7 @@ reveal_type(b) # revealed: Unknown
### Surrogates ### Surrogates
```py ```py
(a, b) = "\uD800\uDFFF" (a, b) = "\ud800\udfff"
reveal_type(a) # revealed: LiteralString reveal_type(a) # revealed: LiteralString
reveal_type(b) # revealed: LiteralString reveal_type(b) # revealed: LiteralString