0
0
mirror of https://github.com/bec-project/bec_widgets.git synced 2025-07-14 11:41:49 +02:00

test: test_extreme.py ErrorHandler tested separately

This commit is contained in:
wyzula-jan
2023-10-10 11:30:52 +02:00
parent 5637c938cf
commit ac2a41d2d8
2 changed files with 93 additions and 6 deletions

View File

@ -1,6 +1,8 @@
import logging
import os
# import traceback
import pyqtgraph
import pyqtgraph as pg
from PyQt5.QtCore import pyqtSignal, pyqtSlot
@ -595,6 +597,7 @@ class ErrorHandler:
logging.basicConfig(level=logging.ERROR) # Configure logging
def handle_error(self, error_message: str, retry_action=None):
# logging.error(f"{error_message}\n{traceback.format_exc()}") #TODO decide if useful
retry_action = self.parent.load_settings_from_yaml
choice = QMessageBox.critical(
@ -679,9 +682,6 @@ class ErrorHandler:
self.errors.append(error_msg)
# TODO add condition for name and entry
def retry_action_test(self):
print("Retry action")
if __name__ == "__main__":
import yaml