'Test lights turn on when coming home after sun set.'

def test_lights_turn_on_when_coming_home_after_sun_set(self):

    test_time = datetime(2017, 4, 5, 3, 2, 3, tzinfo=dt_util.UTC)
    with patch('homeassistant.util.dt.utcnow', return_value=test_time):
        light.turn_off(self.hass)
        self.hass.block_till_done()
        self.assertTrue(setup_component(self.hass, device_sun_light_trigger.DOMAIN, {device_sun_light_trigger.DOMAIN: {}}))
        self.hass.states.set(device_tracker.ENTITY_ID_FORMAT.format('device_2'), STATE_HOME)
        self.hass.block_till_done()
    self.assertTrue(light.is_on(self.hass))
