Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup and simplitfy the async state update #9390

Merged
merged 2 commits into from
Sep 12, 2017

Conversation

pvizeli
Copy link
Member

@pvizeli pvizeli commented Sep 11, 2017

Description:

Simplify the code with a async version of schedule_update_ha_state.

If the code does not interact with devices:

  • Local tests with tox run successfully. Your PR cannot be merged unless tests pass
  • Tests have been added to verify that the new code works.

mock_entity.async_schedule_update_ha_state(True)
yield from hass.async_block_till_done()

assert mock_call.called

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

undefined name 'mock_call'

@pvizeli pvizeli merged commit 90f9a6b into home-assistant:dev Sep 12, 2017
@pvizeli pvizeli deleted the improve_code branch September 12, 2017 08:01
@balloob balloob mentioned this pull request Sep 22, 2017
@home-assistant home-assistant locked and limited conversation to collaborators Dec 11, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants