Skip to content
Snippets Groups Projects
Commit cbacebc9 authored by Corné Lukken's avatar Corné Lukken
Browse files

L2SS-493: Use logger instead of print in TestDeviceProxy

parent 3a5a7f87
No related branches found
No related tags found
1 merge request!183Docker image building & pushing with CI pipeline caching
import logging
import time import time
from tango import DeviceProxy from tango import DeviceProxy
logger = logging.getLogger()
class TestDeviceProxy(DeviceProxy): class TestDeviceProxy(DeviceProxy):
...@@ -16,7 +19,7 @@ class TestDeviceProxy(DeviceProxy): ...@@ -16,7 +19,7 @@ class TestDeviceProxy(DeviceProxy):
d.Off() d.Off()
except Exception as e: except Exception as e:
"""Failing to turn Off devices should not raise errors here""" """Failing to turn Off devices should not raise errors here"""
print(f"Failed to turn device off in teardown {e}") logger.error(f"Failed to turn device off in teardown {e}")
"""Wait for 1 second to prevent propagating reconnection errors""" """Wait for 1 second to prevent propagating reconnection errors"""
time.sleep(1) time.sleep(1)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment