'Test entity hidding.'

def test_hidden(self):

    assert setup_component(self.hass, alert.DOMAIN, TEST_CONFIG)
    hidden = self.hass.states.get(ENTITY_ID).attributes.get('hidden')
    self.assertTrue(hidden)
    self.hass.states.set('sensor.test', STATE_ON)
    self.hass.block_till_done()
    hidden = self.hass.states.get(ENTITY_ID).attributes.get('hidden')
    self.assertFalse(hidden)
    alert.turn_off(self.hass, ENTITY_ID)
    hidden = self.hass.states.get(ENTITY_ID).attributes.get('hidden')
    self.assertFalse(hidden)
