From 16a414fc537f7c4515288570541ba3da887a04b1 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Thu, 5 Sep 2019 13:43:59 +0100 Subject: [PATCH] Don't use watchdog in unit tests --- daemon.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/daemon.py b/daemon.py index 860d318e..984a62a0 100644 --- a/daemon.py +++ b/daemon.py @@ -3523,10 +3523,14 @@ def runDaemon(projectVersion, \ httpd.ocapAlways,maxReplies, \ domainMaxPostsPerDay,accountMaxPostsPerDay, \ allowDeletion,debug,httpd.acceptedCaps),daemon=True) - httpd.thrWatchdog= \ - threadWithTrace(target=runInboxQueueWatchdog, \ - args=(projectVersion,httpd),daemon=True) - httpd.thrWatchdog.start() + if not unitTest: + httpd.thrWatchdog= \ + threadWithTrace(target=runInboxQueueWatchdog, \ + args=(projectVersion,httpd),daemon=True) + httpd.thrWatchdog.start() + else: + httpd.thrInboxQueue.start() + if clientToServer: print('Running ActivityPub client on ' + domain + ' port ' + str(proxyPort)) else: