MCPcopy Create free account
hub / github.com/bslatkin/effectivepython / test_start

Method test_start

example_code/item_109.py:109–114  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

107class ToasterUnitTest(TestCase):
108
109 def test_start(self):
110 timer = Mock(spec=ReusableTimer)
111 toaster = Toaster(timer)
112 toaster.push_down()
113 self.assertTrue(toaster.hot)
114 timer.countdown.assert_called_once_with(30, toaster.pop_up)
115
116 def test_end(self):
117 timer = Mock(spec=ReusableTimer)

Callers

nothing calls this directly

Calls 2

push_downMethod · 0.95
ToasterClass · 0.85

Tested by

no test coverage detected