MCPcopy
hub / github.com/python-attrs/attrs / test_success_with_none

Method test_success_with_none

tests/test_converters.py:148–154  ·  view source on GitHub ↗

Nothing happens if None.

(self)

Source from the content-addressed store, hash-verified

146 assert c("42") == 42
147
148 def test_success_with_none(self):
149 """
150 Nothing happens if None.
151 """
152 c = optional(int)
153
154 assert c(None) is None
155
156 def test_fail(self):
157 """

Callers

nothing calls this directly

Calls 1

optionalFunction · 0.90

Tested by

no test coverage detected