MCPcopy Create free account
hub / github.com/Distributive-Network/PythonMonkey / test_map_check_index

Function test_map_check_index

tests/python/test_arrays.py:1125–1130  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1123
1124
1125def test_map_check_index():
1126 items = [4, 2, 6, 7]
1127 result = ['']
1128 pm.eval("(result, arr) => {arr.map((x, index) => result[0] += index)}")(result, items)
1129 assert items == [4, 2, 6, 7]
1130 assert result[0] == '0123'
1131
1132
1133def test_map_check_array():

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected