forked from espressif/esp-idf
ci: move log dir from pytest_embedded_log to pytest-embedded
This commit is contained in:
@ -39,7 +39,8 @@ from dynamic_pipelines.constants import TEST_RELATED_APPS_DOWNLOAD_URLS_FILENAME
|
||||
from idf_ci.app import import_apps_from_txt
|
||||
from idf_ci.uploader import AppDownloader, AppUploader
|
||||
from idf_ci_utils import IDF_PATH, idf_relpath
|
||||
from idf_pytest.constants import DEFAULT_SDKCONFIG, ENV_MARKERS, SPECIAL_MARKERS, TARGET_MARKERS, PytestCase
|
||||
from idf_pytest.constants import DEFAULT_SDKCONFIG, ENV_MARKERS, SPECIAL_MARKERS, TARGET_MARKERS, PytestCase, \
|
||||
DEFAULT_LOGDIR
|
||||
from idf_pytest.plugin import IDF_PYTEST_EMBEDDED_KEY, ITEM_PYTEST_CASE_KEY, IdfPytestEmbedded
|
||||
from idf_pytest.utils import format_case_id
|
||||
from pytest_embedded.plugin import multi_dut_argument, multi_dut_fixture
|
||||
@ -460,11 +461,12 @@ def pytest_runtest_makereport(item, call): # type: ignore
|
||||
|
||||
job_id = os.getenv('CI_JOB_ID', 0)
|
||||
url = os.getenv('CI_PAGES_URL', '').replace('esp-idf', '-/esp-idf')
|
||||
template = f'{url}/-/jobs/{job_id}/artifacts/pytest_embedded_log/{{}}'
|
||||
template = f'{url}/-/jobs/{job_id}/artifacts/{DEFAULT_LOGDIR}/{{}}'
|
||||
logs_files = []
|
||||
|
||||
def get_path(x: str) -> str:
|
||||
return x.split('pytest_embedded_log/', 1)[1]
|
||||
return x.split(f'{DEFAULT_LOGDIR}/', 1)[1]
|
||||
|
||||
if isinstance(_dut, list):
|
||||
logs_files.extend([template.format(get_path(d.logfile)) for d in _dut])
|
||||
dut_artifacts_url.append('{}:'.format(_dut[0].test_case_name))
|
||||
|
Reference in New Issue
Block a user