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

Method test_these_leave_body

tests/test_make.py:317–327  ·  view source on GitHub ↗

If these is passed, no attributes are removed from the body.

(self)

Source from the content-addressed store, hash-verified

315 assert (simple_attr("x"),) == attrs
316
317 def test_these_leave_body(self):
318 """
319 If these is passed, no attributes are removed from the body.
320 """
321
322 @attr.s(init=False, these={"x": attr.ib()})
323 class C:
324 x = 5
325
326 assert 5 == C().x
327 assert "C(x=5)" == repr(C())
328
329 def test_these_ordered(self):
330 """

Callers

nothing calls this directly

Calls 1

CClass · 0.70

Tested by

no test coverage detected