Skip to content

Commit 9c760fb

Browse files
committed
Add a test
1 parent 7d9dfdd commit 9c760fb

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

integration_tests/str_to_list_cast.py

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,20 @@ def f():
1010
assert len(x) == 0
1111
x = list("L")
1212
assert len(x) == 1 and x[0] == 'L'
13+
x = list(s)
14+
assert len(x) == len(s)
15+
for i in range(len(x)):
16+
assert x[i] == s[i]
17+
s = "agowietg348203wk.smg.afejwp398273wd.a,23to0MEG.F,"
18+
x = list(s)
19+
assert len(x) == len(s)
20+
for i in range(len(x)):
21+
assert x[i] == s[i]
22+
s += str(i)
23+
x = list(s)
24+
assert len(x) == len(s)
25+
for i in range(len(x)):
26+
assert x[i] == s[i]
27+
1328

1429
f()

0 commit comments

Comments
 (0)