'Test with discover of sensor when auto add is False.'

def test_discover_sensor_noautoadd(self):

    self.assertTrue(setup_component(self.hass, 'sensor', {'sensor': {'platform': 'rfxtrx', 'automatic_add': False, 'devices': {}}}))
    event = rfxtrx_core.get_rfx_object('0a520801070100b81b0279')
    event.data = bytearray('\nR\x08\x01\x07\x01\x00\xb8\x1b\x02y')
    self.assertEqual(0, len(rfxtrx_core.RFX_DEVICES))
    rfxtrx_core.RECEIVED_EVT_SUBSCRIBERS[0](event)
    self.assertEqual(0, len(rfxtrx_core.RFX_DEVICES))
    rfxtrx_core.RECEIVED_EVT_SUBSCRIBERS[0](event)
    self.assertEqual(0, len(rfxtrx_core.RFX_DEVICES))
    event = rfxtrx_core.get_rfx_object('0a52080405020095240279')
    event.data = bytearray('\nR\x08\x04\x05\x02\x00\x95$\x02y')
    rfxtrx_core.RECEIVED_EVT_SUBSCRIBERS[0](event)
    self.assertEqual(0, len(rfxtrx_core.RFX_DEVICES))
    event = rfxtrx_core.get_rfx_object('0a52085e070100b31b0279')
    event.data = bytearray('\nR\x08^\x07\x01\x00\xb3\x1b\x02y')
    rfxtrx_core.RECEIVED_EVT_SUBSCRIBERS[0](event)
    self.assertEqual(0, len(rfxtrx_core.RFX_DEVICES))
