]> Git Repo - J-u-boot.git/blob - test/py/tests/test_semihosting/conftest.py
Merge tag 'u-boot-imx-master-20250127' of https://gitlab.denx.de/u-boot/custodians...
[J-u-boot.git] / test / py / tests / test_semihosting / conftest.py
1 # SPDX-License-Identifier: GPL-2.0-or-later
2
3 """Fixture for semihosting command test
4 """
5
6 import os
7 import pytest
8
9 @pytest.fixture(scope='session')
10 def semihosting_data(u_boot_config):
11     """Set up a file system to be used in semihosting tests
12
13     Args:
14         u_boot_config -- U-Boot configuration.
15     """
16     image_path = u_boot_config.persistent_data_dir + '/semihosting.txt'
17
18     with open(image_path, 'w', encoding = 'utf-8') as file:
19         file.write('Das U-Boot\n')
20
21     yield image_path
22
23     os.remove(image_path)
This page took 0.030508 seconds and 4 git commands to generate.