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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove weird tests #12936

Merged
merged 4 commits into from Mar 6, 2018
Merged

Remove weird tests #12936

merged 4 commits into from Mar 6, 2018

Conversation

balloob
Copy link
Member

@balloob balloob commented Mar 6, 2018

Description:

More test fixes.

Mediaroom test didn't test anything, was actually just running code and took on my machine 60 seconds.

The meraki tests were actually doing Mac vendor lookups 馃憥

(realized that this was also the problem with DDWRT tests but they are disabled now and can't be bothered to fix them)

Fixed flakiness of TestComponentsDeviceTracker.test_adding_unknown_device_to_config by removing all I/O from test

Related issue (if applicable): #12931

@homeassistant homeassistant added cla-signed small-pr PRs with less than 30 lines. labels Mar 6, 2018
side_effect=mock_update_config
), patch(
'homeassistant.components.device_tracker.async_load_config',
side_effect=lambda *args: mock_coro(devices)
Copy link
Member

Choose a reason for hiding this comment

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

Are lambda function coroutines/do the inherit it in some way?

Lambda functions does not seem to be async yet according to PEP492

Copy link
Member Author

Choose a reason for hiding this comment

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

Async functions return coroutines when called. These can be awaited to execute it and get the result. So in this case the lamda passes the coroutine to the caller.

@kellerza kellerza merged commit 36b9c0a into dev Mar 6, 2018
@kellerza kellerza deleted the remove-weird-tests branch March 6, 2018 19:53
@balloob balloob mentioned this pull request Mar 9, 2018
@home-assistant home-assistant locked and limited conversation to collaborators Jul 26, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
cla-signed small-pr PRs with less than 30 lines.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants