Esempio n. 1
0
    def test___noop__(self, debug):
        """Assert correct behavior from the __noop__ method."""
        bt = bugs.FakeBugTracker()

        bt.__noop__(1, 2)

        debug.assert_called_once_with('__noop__((1, 2))')
Esempio n. 2
0
    def test_getbug(self):
        """Ensure correct return value of the getbug() method."""
        bt = bugs.FakeBugTracker()

        b = bt.getbug(1234)

        self.assertTrue(isinstance(b, bugs.FakeBug))
        self.assertEqual(b.bug_id, 1234)
Esempio n. 3
0
    def test_getbug(self):
        """Ensure correct return value of the getbug() method."""
        bt = bugs.FakeBugTracker()

        b = bt.getbug(1234)

        assert isinstance(b, bugs.FakeBug)
        assert b.bug_id == 1234