Skip to content

Commit 6803cee

Browse files
Copilotyouknowone
andcommitted
Fix ruff formatting in builtin_ascii.py snippet
Co-authored-by: youknowone <69878+youknowone@users.noreply.github.com>
1 parent 18fb23e commit 6803cee

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

extra_tests/snippets/builtin_ascii.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,21 @@
66
assert ascii(chr(0x9999)) == "'\\u9999'"
77
assert ascii(chr(0x0A)) == "'\\n'"
88

9+
910
class MyStr(str):
1011
pass
1112

13+
1214
class Foo:
1315
def __repr__(self):
1416
return MyStr("hello")
1517

18+
1619
class Bar:
1720
def __repr__(self):
1821
return MyStr("héllo")
1922

23+
2024
assert type(ascii(Foo())) is MyStr
2125
assert ascii(Foo()) == MyStr("hello")
2226
assert type(ascii(Bar())) is str

0 commit comments

Comments
 (0)