Skip to content
Snippets Groups Projects
Commit 59318a8b authored by lukas leufen's avatar lukas leufen
Browse files

add short sleep

parent bb7fa953
No related branches found
No related tags found
2 merge requests!17update to v0.4.0,!16handle station type
Pipeline #26608 passed
import logging
import pytest
import time
from src.helpers import PyTestRegex
from src.modules.experiment_setup import ExperimentSetup
......@@ -13,7 +14,8 @@ class TestPreProcessing:
@pytest.fixture
def obj_no_init(self):
return object.__new__(PreProcessing)
yield object.__new__(PreProcessing)
RunEnvironment().__del__()
@pytest.fixture
def obj_super_init(self):
......@@ -41,6 +43,7 @@ class TestPreProcessing:
var_all_dict={'o3': 'dma8eu', 'temp': 'maximum'})
caplog.set_level(logging.INFO)
PreProcessing()
time.sleep(0.001) # sometimes the destruction logging is delayed during CI testing, so wait a little
assert caplog.record_tuples[0] == ('root', 20, 'PreProcessing started')
assert caplog.record_tuples[1] == ('root', 20, 'check valid stations started')
assert caplog.record_tuples[-2] == ('root', 20, PyTestRegex(r'run for \d+\.\d+s to check 5 station\(s\). Found '
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment