'Test setup when connection error occurs.'

@patch('pmsensor.co2sensor.read_mh_z19', side_effect=OSError('test    error'))
def test_setup_failed_connect(self, mock_co2):

    self.assertFalse(mhz19.setup_platform(self.hass, {'platform': 'mhz19', mhz19.CONF_SERIAL_DEVICE: 'test.serial'}, None))
