MCPcopy Create free account
hub / github.com/pybind/pybind11 / test_negate

Function test_negate

tests/test_docs_advanced_cast_custom.py:23–31  ·  view source on GitHub ↗
(doc: SanitizedString)

Source from the content-addressed store, hash-verified

21
22
23def test_negate(doc: SanitizedString) -> None:
24 assert (
25 doc(m.negate)
26 == "negate(arg0: collections.abc.Sequence[float]) -> tuple[float, float]"
27 )
28 assert_negate_function([1.0, -1.0], (-1.0, 1.0))
29 assert_negate_function((1.0, -1.0), (-1.0, 1.0))
30 assert_negate_function([1, -1], (-1.0, 1.0))
31 assert_negate_function((1, -1), (-1.0, 1.0))
32
33
34def test_docs() -> None:

Callers

nothing calls this directly

Calls 2

assert_negate_functionFunction · 0.85
docFunction · 0.70

Tested by

no test coverage detected