diff --git a/config.json b/config.json index 179a9ce..f72ac1f 100644 --- a/config.json +++ b/config.json @@ -105,6 +105,7 @@ { "type": "midi_peer", "host": "tracks", "session": "NA Tracks", "peer": "SuperRack-LiveBox", "tag": "TRK LIVEBOX", "fix": "midi_reconnect", "address": "10.1.13.140:5004" }, { "type": "midi_peer", "host": "tracks", "session": "NA Tracks", "peer": "Studio B Mac Studio", "tag": "TRK STUDIO B", "fix": "midi_reconnect", "address": "\tStudio B Mac Studio\tlocal." }, { "type": "midi_peer", "host": "prop", "session": "NA ProP", "peer": "Lighting PC", "tag": "PROP LIGHTS", "fix": "midi_reconnect", "address": "10.1.10.206:5004" }, + { "type": "conn", "conn": "lighting-midi", "tag": "COMPANION MIDI" }, { "type": "mdns", "instance": "Lighting PC", "name": "LIGHT PC MIDI", "fix": "rtpmidi_start" }, { "type": "mdns", "instance": "NA Tracks", "name": "TRACKS MIDI" }, { "type": "midi_rx", "source": "Network NA Ingest Listen", "name": "TRACKS IN" } @@ -119,6 +120,7 @@ { "type": "remote", "host": "tracks", "cmd": "pgrep -xq Live", "msg": "ABLETON NOT RUNNING", "fix": "ableton" }, { "type": "remote", "host": "translation", "cmd": "pgrep -xq 'Church Translate'", "msg": "TRANSLATE NOT RUNNING", "fix": "translate" }, { "type": "ping", "host": "10.1.3.227", "name": "TRACKS MAC" }, + { "type": "http", "url": "http://10.1.14.225:1025/", "msg": "PROP TV DOWN", "interval_seconds": 5, "fix": "propresenter" }, { "type": "http", "url": "http://10.6.7.13:8080/", "msg": "BIBLE APP DOWN", "interval_seconds": 5, "fix": "bibleapp" }, { "type": "conn", "conn": "BibleTV", "tag": "BIBLE OSC" } ] }, diff --git a/tests/test_status_panel.py b/tests/test_status_panel.py index ca5ce52..209aee7 100644 --- a/tests/test_status_panel.py +++ b/tests/test_status_panel.py @@ -69,7 +69,7 @@ def healthy_snapshot(now): snap.launchd = {"org.waterschurch.resi-propresenter": 884, "org.waterschurch.lobby-captions": 900} snap.launchd_time = now snap.procs = {"/Applications/ProdDash.app/Contents/MacOS/ProdDash": True} - snap.http = {"https://central.resi.io/": True, "http://10.6.7.13:8080/": True} + snap.http = {"https://central.resi.io/": True, "http://10.6.7.13:8080/": True, "http://10.1.14.225:1025/": True} snap.disk = {"/": 97} return snap @@ -251,6 +251,15 @@ class TestChecks(unittest.TestCase): finally: stop.set() + def test_companion_midi_and_prop_tv(self): + engine = sp.Engine(CONFIG) + self.snap.conns["lighting-midi"]["category"] = "error" + self.snap.http["http://10.1.14.225:1025/"] = False + tiles, _ = run_steps(engine, self.snap, self.now, 4) + self.assertEqual(tiles["midi"]["x"], "MIDI\nCOMPANION MIDI OFFLINE") + self.assertEqual(tiles["apps"]["x"], "APPS\nPROP TV DOWN") + self.assertEqual(dict(sp.http_checks(CONFIG))["http://10.1.14.225:1025/"], 5) + def test_propresenter_yellow_warning_is_ignored(self): engine = sp.Engine(CONFIG) self.snap.conns["Propresenter-API"].update(category="warning", message="Socket closed")