hass-core/tests/components/lock
Andrew Hayworth 5ae65142b8 Allow verisure locks to be configured with a default code (#18873)
* Allow verisure locks to be configured with a default code

* linting fix

* PR feedback

* PR feedback - try harder to prevent future typos

A python mock is a magical thing, and will respond to basicaly
any method you call on it. It's somewhat better to assert against
an explicit variable named 'mock', rather than to assert on the
method name you wanted to mock... could prevent a typo from messing up
tests.

* PR feedback: convert tests to integration-style tests

Set up a fake verisure hub, stub out a _lot_ of calls, then test
after platform discovery and service calls.

It should be noted that we're overriding the `update()` calls in
these tests. This was done to prevent even further mocking of
the verisure hub's responses.

Hopefully, this'll be a foundation for people to write more tests.

* more pr feedback
2018-12-03 07:25:54 +01:00
..
__init__.py
common.py Remove service helper (4) (#16892) 2018-09-26 18:02:05 +02:00
test_demo.py Pytest tests (#17750) 2018-10-24 12:10:05 +02:00
test_mqtt.py Move more MQTT platforms to config entries (#18180) 2018-11-06 16:09:46 +01:00
test_template.py Template Lock (#17288) 2018-10-11 12:53:54 +02:00
test_verisure.py Allow verisure locks to be configured with a default code (#18873) 2018-12-03 07:25:54 +01:00
test_zwave.py Update Z-Wave Tests asyncio/yield from -> async/await (#18599) 2018-11-20 14:58:03 -05:00