MCPcopy Create free account
hub / github.com/dot-agent/nextpy / items

Method items

integration/utils.py:60–71  ·  view source on GitHub ↗

Get all items in local storage. Returns: A dict mapping keys to values.

(self)

Source from the content-addressed store, hash-verified

58 return int(self.driver.execute_script("return window.localStorage.length;"))
59
60 def items(self) -> dict[str, str]:
61 """Get all items in local storage.
62
63 Returns:
64 A dict mapping keys to values.
65 """
66 return self.driver.execute_script(
67 "var ls = window.localStorage, items = {}; "
68 "for (var i = 0, k; i < ls.length; ++i) "
69 " items[k = ls.key(i)] = ls.getItem(k); "
70 "return items; "
71 )
72
73 def keys(self) -> list[str]:
74 """Get all keys in local storage.

Callers 15

test_clear_filesFunction · 0.80
test_client_side_stateFunction · 0.80
setMethod · 0.80
_reverse_mappingFunction · 0.80
get_frontend_packagesMethod · 0.80
compile_Method · 0.80
upload_fileFunction · 0.80
get_serializerFunction · 0.80
serialize_dictFunction · 0.80
format_propsFunction · 0.80
format_query_paramsFunction · 0.80

Calls

no outgoing calls

Tested by 6

test_clear_filesFunction · 0.64
test_client_side_stateFunction · 0.64
compare_dict_of_varFunction · 0.64
test_replace_defaultsFunction · 0.64
test_format_tagFunction · 0.64