app container and config schema

This commit is contained in:
Blake Blackshear
2020-11-01 06:17:44 -06:00
parent 732e91ee42
commit a8964dcc1f
8 changed files with 227 additions and 14 deletions

View File

@@ -0,0 +1,26 @@
import json
from unittest import TestCase, main
import voluptuous as vol
from frigate.config import FRIGATE_CONFIG_SCHEMA
class TestConfig(TestCase):
def test_empty(self):
FRIGATE_CONFIG_SCHEMA({})
def test_minimal(self):
minimal = {
'mqtt': {
'host': 'mqtt'
},
'cameras': {
'back': {
'ffmpeg': {
'input': 'rtsp://10.0.0.1:554/video'
}
}
}
}
FRIGATE_CONFIG_SCHEMA(minimal)
if __name__ == '__main__':
main(verbosity=2)