Jan Harkes
cbe9a7d2a3
Add case insensitive testing to boolean string validation.
2016-04-03 21:38:58 -07:00
Paulus Schoutsen
e140e9b8ab
Add script + extra config validators
...
* Add config validation and extra validators
* Address PR comments
2016-04-03 10:19:09 -07:00
Paulus Schoutsen
5baa98b79f
Add initial config validation
2016-03-28 23:46:12 -07:00
Paulus Schoutsen
ddc139b853
Merge pull request #1510 from persandstrom/automation_templating
...
Use templates in service calls
2016-03-11 21:49:47 -08:00
Per Sandström
81e5a852f0
Use templates in service calls
2016-03-10 21:36:05 +01:00
MartinHjelmare
c56701baaf
Refactor reproduce_state for scene component
...
* Add tests to reach full coverage for helpers/state.py.
* Refactor reproduce_state function in helpers/state.py. Add two dicts,
as global constants, service_attributes and service_to_state. Use
these in combination with the dict of services per domain from
ServiceRegistry, to find the correct service to use in a scene state
change.
* Use break statement in for loop, to break if service was selected
to update state, in preference to update state attributes, ie state
update takes precedence.
* Add ATTR_CODE and ATTR_CODE_FORMAT in const. Import these in
alarm_control_panel and lock platforms instead of making duplicate
constants in multiple modules.
* Use ATTR_MEDIA_CONTENT_TYPE and ATTR_MEDIA_CONTENT_ID in media_player
platform in SERVICE_PLAY_MEDIA and play_media methods, instead of
'media_type' and 'media_id'.
* Fix PEP257 in modified files.
2016-03-09 18:52:05 +01:00
Fabian Affolter
f22a40c3e8
Fix PEP257 issues
2016-03-09 11:15:04 +01:00
Fabian Affolter
9838697d2b
Fix PEP257 issues
2016-03-09 10:25:50 +01:00
Paulus Schoutsen
cd30f2de0d
Device Sun Light Trigger: Clean up
2016-03-05 20:15:33 -08:00
Dan Smith
db4bf7319f
Add float() operator to templates
2016-02-24 20:07:46 -08:00
Fabian Affolter
6b4dd64cfe
Add break to fix length of lines
2016-02-23 22:06:45 +01:00
Fabian Affolter
582394bc3b
Modify import of template and PEP257
2016-02-23 21:19:22 +01:00
Fabian Affolter
213cc920d0
Move template to helpers
2016-02-23 21:19:10 +01:00
Paulus Schoutsen
c3bb6d32aa
Add closest template helper
2016-02-21 11:13:40 -08:00
Paulus Schoutsen
09ab3e95c0
Tests should all use test HA
2016-02-14 15:08:23 -08:00
Paulus Schoutsen
bade0e0d71
Make tests pass flake8
2016-02-14 13:07:21 -08:00
Paulus Schoutsen
ada2fb4ec0
Fire event when we remove a state
2016-02-13 22:57:40 -08:00
Paulus Schoutsen
bf0b453677
Merge branch 'hotfix/state-as-number' into dev
...
Conflicts:
homeassistant/const.py
tests/helpers/test_state.py
2016-02-13 08:32:06 -08:00
Fabian Affolter
00afaac54c
Update for file header, docstrings, and PEP8/PEP257
2016-02-13 14:19:11 +01:00
Paulus Schoutsen
1571b33e4a
Fix: state_as_number always return float
2016-02-13 00:08:32 -08:00
Dan Smith
3aa34deaa2
Add state_as_number() helper
...
This adds state_as_number(), a helper method that tries to interpret
state as a number, for cases we can predict. It's a generalization of
what is copy-and-paste-ed into multiple other places.
2016-02-12 00:41:32 +00:00
Paulus Schoutsen
fce8815ab4
Support custom interval for platforms
2016-01-31 01:01:23 -08:00
Paulus Schoutsen
90e17fc77f
Add tests for entity component
2016-01-31 01:01:23 -08:00
magnusknutas
2382dffbf4
pushed test code :) fixed now
2016-01-26 20:49:51 +01:00
magnusknutas
33b0f4d05d
Fixes bug in time trigger and adds test for ex. /two
2016-01-26 20:43:29 +01:00
magnusknutas
cff77a175d
Year periodic test (just to trigger travis but should maybe be here anyway)
2016-01-26 18:44:41 +01:00
magnusknutas
726637b867
New and improved handling of the matching! Kudos to @balloob
2016-01-26 18:37:19 +01:00
magnusknutas
a918be517d
test past midnight support for hours
2016-01-26 17:13:18 +01:00
magnusknutas
ec5d88b98e
hourly periodic task
2016-01-26 17:06:50 +01:00
magnusknutas
13fbefcdf8
Running periodic tasks
2016-01-26 10:28:31 +01:00
Paulus Schoutsen
bb3dd47088
Merge pull request #992 from balloob/sections
...
Add support for sections in the frontend [Fixes #100705168 ]
2016-01-24 22:58:27 -08:00
Paulus Schoutsen
f6c53896e3
Allow groups to be used as views
2016-01-24 22:54:45 -08:00
Ryan Kraus
60dd2d441d
Merge remote-tracking branch 'balloob/dev' into automation-decorator
...
# Conflicts:
# homeassistant/helpers/service.py
# tests/helpers/test_service.py
2016-01-24 22:51:00 -05:00
Ryan Kraus
5830da63b1
Moved service decorator to service helpers
...
Moved the service decorator to the service helpers module and moved the
associated tests.
2016-01-24 22:46:30 -05:00
Ryan Kraus
f66aeb2e73
Added event helper tests
...
1. Added tests for all event decorators
2. Added tests for sunrise and sunset event helpers
2016-01-24 22:23:56 -05:00
Paulus Schoutsen
de79a46d43
Move extract_entity_id to service helpers
2016-01-23 22:57:14 -08:00
Paulus Schoutsen
bc19ef66bf
Move split_entity_id to helpers
2016-01-23 22:49:49 -08:00
Paulus Schoutsen
73cdf00512
More service helper tests
2016-01-09 16:01:27 -08:00
Paulus Schoutsen
12b5caed70
ps - strip entity IDs in service call
2016-01-09 15:51:51 -08:00
Paulus Schoutsen
736183e6f5
Fix bug in reproduce_state with complex state attributes
2016-01-03 11:27:30 -08:00
Paulus Schoutsen
f8b2570cb3
Group entities when reproducing a state
2016-01-03 02:32:09 -08:00
Paulus Schoutsen
68c2b539ee
More flexible domain config extraction
2015-09-28 23:09:05 -07:00
Paulus Schoutsen
cfc23b0091
Speed up tests
2015-09-12 22:56:49 -07:00
Paulus Schoutsen
4ccedca3e5
Fix tests for device tracker
2015-09-12 09:15:28 -07:00
Paulus Schoutsen
58afbecd05
Speed up tests
2015-09-01 00:18:26 -07:00
Paulus Schoutsen
1b89a502c4
Extract core into own submodule
2015-08-16 20:44:46 -07:00
Paulus Schoutsen
2075de3d81
Extended test_init tests to cover all
2015-08-04 18:16:10 +02:00
Paulus Schoutsen
e0468f8b8e
Extract helpers.event from core + misc cleanup
2015-07-26 10:45:49 +02:00
Paulus Schoutsen
0c56fde5a9
Reorg tests folder
2015-07-26 10:17:01 +02:00