MCPcopy Create free account
hub / github.com/cdgriffith/Box / Rows

Class Rows

test/test_box_list.py:57–64  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

55 def test_box_list_does_not_require_iterable_truth_value(self, falsey):
56 # 2026-10-10: Iterable inputs can be falsey or have no boolean value.
57 class Rows:
58 def __iter__(self):
59 return iter([{"value": 1}])
60
61 def __bool__(self):
62 if falsey:
63 return False
64 raise ValueError("ambiguous truth value")
65
66 result = BoxList(Rows())
67 assert len(result) == 1

Calls

no outgoing calls