def test_run_stops(self):
        with mock.patch.object(self.gf, '_queue') as mock_queue:
            mock_queue.get.return_value = self.gf._quit_object
            self.assertEqual(None, self.gf.run())
            mock_queue.get.assert_called_once_with()
            mock_queue.task_done.assert_called_once_with()
Test the stops.
dataset/ETHPy150Open home-assistant/home-assistant/tests/components/test_graphite.py/TestGraphite.test_run_stops