Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
Indexed
MCP
copy
Index your code
hub
/
github.com/pre-commit/pre-commit
/ test_mapping_key
Function
test_mapping_key
tests/yaml_rewrite_test.py:33–36 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
31
32
33
def
test_mapping_key():
34
m = MappingKey(
's'
)
35
ret = [n.value
for
n in m.match(yaml_compose(
's: val\nt: val2'
))]
36
assert ret == [
's'
]
37
38
39
def
test_mapping_value():
Callers
nothing calls this directly
Calls
2
match
Method · 0.95
MappingKey
Class · 0.90
Tested by
no test coverage detected