Mock call to google servers (#4532)

* Fix for #4520

* mock call to do_auth to prevent call to google servers
This commit is contained in:
mnestor 2016-11-22 21:19:32 -05:00 committed by Paulus Schoutsen
parent 2c7e895105
commit 962e5315ab
2 changed files with 3 additions and 1 deletions

0
tests/components/calendar/test_google.py Normal file → Executable file
View File

View File

@ -1,6 +1,7 @@
"""The tests for the Google Calendar component."""
import logging
import unittest
from unittest.mock import patch
import homeassistant.components.google as google
from homeassistant.bootstrap import setup_component
@ -20,7 +21,8 @@ class TestGoogle(unittest.TestCase):
"""Stop everything that was started."""
self.hass.stop()
def test_setup_component(self):
@patch('homeassistant.components.google.do_authentication')
def test_setup_component(self, mock_do_auth):
"""Test setup component."""
config = {
'google': {