def METHOD_NAME(self, mock_write, mock_get_hub):
    self._test_event_closed_on_io_error(os.nb_write, b'buf',
                                        mock_write, mock_get_hub,
                                        2)