mirror of
https://github.com/home-assistant/core.git
synced 2025-12-24 21:06:19 +00:00
WIP Fix pylint and PEP257 issues (tests) (#4120)
* Fix pylint and PEP257 issues * More PEP257 fixes
This commit is contained in:
committed by
Paulus Schoutsen
parent
443553ff16
commit
51e20c92f9
@@ -179,6 +179,7 @@ class TestNX584Watcher(unittest.TestCase):
|
||||
|
||||
@mock.patch.object(watcher, '_process_zone_event')
|
||||
def run(fake_process):
|
||||
"""Run a fake process."""
|
||||
fake_process.side_effect = StopMe
|
||||
self.assertRaises(StopMe, watcher._run)
|
||||
self.assertEqual(fake_process.call_count, 1)
|
||||
@@ -193,6 +194,7 @@ class TestNX584Watcher(unittest.TestCase):
|
||||
empty_me = [1, 2]
|
||||
|
||||
def fake_run():
|
||||
"""Fake runner."""
|
||||
if empty_me:
|
||||
empty_me.pop()
|
||||
raise requests.exceptions.ConnectionError()
|
||||
|
||||
Reference in New Issue
Block a user