Skip to content

Commit 7cfc132

Browse files
committed
fix the test
1 parent add7ced commit 7cfc132

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

tests/units/components/core/test_foreach.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,6 @@ def display_color_index_tuple(color):
141141
return box(text(color))
142142

143143

144-
seen_index_vars = set()
145-
146-
147144
@pytest.mark.parametrize(
148145
("state_var", "render_fn", "render_dict"),
149146
[
@@ -248,10 +245,7 @@ def test_foreach_render(state_var, render_fn, render_dict):
248245

249246
# Make sure the index vars are unique.
250247
arg_index = rend["arg_index"]
251-
assert isinstance(arg_index, Var)
252-
assert arg_index._js_expr not in seen_index_vars
253-
assert arg_index._var_type is int
254-
seen_index_vars.add(arg_index._js_expr)
248+
assert isinstance(arg_index, str)
255249

256250

257251
def test_foreach_bad_annotations():

0 commit comments

Comments
 (0)