]> git.ipfire.org Git - thirdparty/pdns.git/blobdiff - regression-tests.recursor-dnssec/test_API.py
Merge pull request #13923 from rgacogne/ddist-xfr-response-chain
[thirdparty/pdns.git] / regression-tests.recursor-dnssec / test_API.py
index 29ec49718b59770ad1ad0095144ade05fc9c2eff..07fc05aa154aa6827d47654f4312b0d2fcaf670d 100644 (file)
@@ -39,6 +39,7 @@ api-key=%s
 """ % (_wsPort, _wsPassword, _apiKey)
 
     def testAPI(self):
+        self.waitForTCPSocket("127.0.0.1", self._wsPort)
         headers = {'x-api-key': self._apiKey}
         url = 'http://127.0.0.1:' + str(self._wsPort) + '/api/v1/servers/localhost/statistics'
         r = requests.get(url, headers=headers, timeout=self._wsTimeout)
@@ -63,6 +64,7 @@ api-key=%s
 """ % (_wsPort, _wsPassword, _apiKey)
 
     def testAPI(self):
+        self.waitForTCPSocket("127.0.0.1", self._wsPort)
         headers = {'x-api-key': self._apiKey}
         url = 'http://127.0.0.1:' + str(self._wsPort) + '/api/v1/servers/localhost/statistics'
         try: