Merge branch 'ci/enable_s31_target_test' into 'master'

ci(esp32s31): Add ci target test for esp32s31

Closes IDF-14694

See merge request espressif/esp-idf!47208
This commit is contained in:
C.S.M
2026-04-03 13:23:47 +08:00
41 changed files with 116 additions and 42 deletions
-1
View File
@@ -12,7 +12,6 @@
bypass_check_test_targets: bypass_check_test_targets:
- esp32h21 - esp32h21
- esp32h4 - esp32h4
- esp32s31
# #
# These lines would # These lines would
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Unlicense OR CC0-1.0 # SPDX-License-Identifier: Unlicense OR CC0-1.0
import re import re
@@ -19,6 +19,7 @@ TEST_SUBMENU_PATTERN_PYTEST = re.compile(rb'\s+\((\d+)\)\s+"([^"]+)"\r?\n')
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_app_update(dut: Dut) -> None: def test_app_update(dut: Dut) -> None:
dut.run_all_single_board_cases(timeout=180) dut.run_all_single_board_cases(timeout=180)
@@ -32,6 +33,7 @@ def test_app_update(dut: Dut) -> None:
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_app_update_xip_psram(dut: Dut) -> None: def test_app_update_xip_psram(dut: Dut) -> None:
dut.run_all_single_board_cases(timeout=180) dut.run_all_single_board_cases(timeout=180)
@@ -45,6 +47,7 @@ def test_app_update_xip_psram(dut: Dut) -> None:
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_app_update_xip_psram_rom_impl(dut: Dut) -> None: def test_app_update_xip_psram_rom_impl(dut: Dut) -> None:
dut.run_all_single_board_cases(timeout=180) dut.run_all_single_board_cases(timeout=180)
+2 -1
View File
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Unlicense OR CC0-1.0 # SPDX-License-Identifier: Unlicense OR CC0-1.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -10,6 +10,7 @@ from pytest_embedded_idf.utils import idf_parametrize
) )
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_efuse(dut: Dut) -> None: def test_efuse(dut: Dut) -> None:
dut.run_all_single_board_cases() dut.run_all_single_board_cases()
@@ -4,6 +4,10 @@ components/esp_driver_dma/test_apps/dma:
disable: disable:
- if: SOC_GDMA_SUPPORTED != 1 and SOC_CP_DMA_SUPPORTED != 1 - if: SOC_GDMA_SUPPORTED != 1 and SOC_CP_DMA_SUPPORTED != 1
- if: CONFIG_NAME == "flash_enc" and SOC_FLASH_ENC_SUPPORTED != 1 - if: CONFIG_NAME == "flash_enc" and SOC_FLASH_ENC_SUPPORTED != 1
disable_test:
- if: IDF_TARGET in ["esp32s31"]
temporary: true
reason: cannot pass # TODO: IDF-15527
depends_components: depends_components:
- esp_driver_dma - esp_driver_dma
- esp_hal_dma - esp_hal_dma
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0 # SPDX-License-Identifier: CC0-1.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2023-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2023-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0 # SPDX-License-Identifier: CC0-1.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -16,6 +16,7 @@ from pytest_embedded_idf.utils import soc_filtered_targets
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_i2c(dut: Dut) -> None: def test_i2c(dut: Dut) -> None:
dut.run_all_single_board_cases() dut.run_all_single_board_cases()
@@ -75,5 +75,6 @@ def test_ledc_psram(dut: IdfDut) -> None:
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_ledc_multi_device(case_tester) -> None: # type: ignore def test_ledc_multi_device(case_tester) -> None: # type: ignore
case_tester.run_all_multi_dev_cases(reset=True) case_tester.run_all_multi_dev_cases(reset=True)
@@ -14,7 +14,7 @@ from pytest_embedded_idf.utils import idf_parametrize
], ],
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['esp32', 'esp32s3', 'esp32c6', 'esp32h2', 'esp32p4'], indirect=['target']) @idf_parametrize('target', ['esp32', 'esp32s3', 'esp32c6', 'esp32h2', 'esp32p4', 'esp32s31'], indirect=['target'])
def test_mcpwm(dut: Dut) -> None: def test_mcpwm(dut: Dut) -> None:
dut.run_all_single_board_cases() dut.run_all_single_board_cases()
@@ -85,5 +85,6 @@ def test_master_esp_flash(case_tester) -> None: # type: ignore
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_master_multi_dev(case_tester) -> None: # type: ignore def test_master_multi_dev(case_tester) -> None: # type: ignore
case_tester.run_all_multi_dev_cases(reset=True) case_tester.run_all_multi_dev_cases(reset=True)
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2021-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2021-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
import pytest import pytest
from pytest_embedded_idf.utils import idf_parametrize from pytest_embedded_idf.utils import idf_parametrize
@@ -6,6 +6,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_param_single_dev(case_tester) -> None: # type: ignore def test_param_single_dev(case_tester) -> None: # type: ignore
case_tester.run_all_normal_cases(reset=True) case_tester.run_all_normal_cases(reset=True)
@@ -13,5 +14,6 @@ def test_param_single_dev(case_tester) -> None: # type: ignore
@pytest.mark.generic_multi_device @pytest.mark.generic_multi_device
@pytest.mark.parametrize('count', [2], indirect=True) @pytest.mark.parametrize('count', [2], indirect=True)
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_param_multi_dev(case_tester) -> None: # type: ignore def test_param_multi_dev(case_tester) -> None: # type: ignore
case_tester.run_all_multi_dev_cases(reset=True) case_tester.run_all_multi_dev_cases(reset=True)
@@ -32,5 +32,6 @@ def test_slave_single_dev_esp32c5_rev1(case_tester) -> None: # type: ignore
@pytest.mark.generic_multi_device @pytest.mark.generic_multi_device
@pytest.mark.parametrize('count, config', [(2, 'release'), (2, 'iram_safe')], indirect=True) @pytest.mark.parametrize('count, config', [(2, 'release'), (2, 'iram_safe')], indirect=True)
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_slave_multi_dev(case_tester) -> None: # type: ignore def test_slave_multi_dev(case_tester) -> None: # type: ignore
case_tester.run_all_multi_dev_cases(reset=True) case_tester.run_all_multi_dev_cases(reset=True)
@@ -29,6 +29,7 @@ input_argv = {
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_uart_single_dev(case_tester) -> None: # type: ignore def test_uart_single_dev(case_tester) -> None: # type: ignore
dut = case_tester.first_dut dut = case_tester.first_dut
chip_type = dut.app.target chip_type = dut.app.target
@@ -82,6 +83,7 @@ def test_uart_single_dev_psram(case_tester) -> None: # type: ignore
@pytest.mark.temp_skip_ci(targets=['esp32', 'esp32s3'], reason='no multi-dev runner') @pytest.mark.temp_skip_ci(targets=['esp32', 'esp32s3'], reason='no multi-dev runner')
@pytest.mark.generic_multi_device @pytest.mark.generic_multi_device
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
@pytest.mark.parametrize( @pytest.mark.parametrize(
'config', 'config',
[ [
@@ -15,6 +15,8 @@ from pytest_embedded_idf.utils import soc_filtered_targets
], ],
indirect=True, indirect=True,
) )
@idf_parametrize('target', soc_filtered_targets('SOC_PAU_SUPPORTED == 1'), indirect=['target']) @idf_parametrize(
'target', soc_filtered_targets('SOC_PAU_SUPPORTED == 1 and SOC_LIGHT_SLEEP_SUPPORTED == 1'), indirect=['target']
)
def test_sleep_retention(dut: Dut) -> None: def test_sleep_retention(dut: Dut) -> None:
dut.run_all_single_board_cases() dut.run_all_single_board_cases()
@@ -43,7 +43,11 @@ available_rtcio_nums = {
@pytest.mark.generic_multi_device @pytest.mark.generic_multi_device
@pytest.mark.parametrize('count', [2], indirect=True) @pytest.mark.parametrize('count', [2], indirect=True)
@pytest.mark.parametrize('config', TEST_CONFIGS, indirect=True) @pytest.mark.parametrize('config', TEST_CONFIGS, indirect=True)
@idf_parametrize('target', soc_filtered_targets('SOC_PM_SUPPORT_EXT1_WAKEUP == 1'), indirect=['target']) @idf_parametrize(
'target',
soc_filtered_targets('SOC_PM_SUPPORT_EXT1_WAKEUP == 1 and SOC_DEEP_SLEEP_SUPPORTED == 1'),
indirect=['target'],
)
def test_ext1_deepsleep(dut: tuple[IdfDut, IdfDut]) -> None: def test_ext1_deepsleep(dut: tuple[IdfDut, IdfDut]) -> None:
wakee = dut[0] wakee = dut[0]
waker = dut[1] waker = dut[1]
@@ -140,6 +144,7 @@ def test_rtcio_deepsleep(dut: tuple[IdfDut, IdfDut]) -> None:
@pytest.mark.parametrize('count', [2], indirect=True) @pytest.mark.parametrize('count', [2], indirect=True)
@pytest.mark.parametrize('config', TEST_CONFIGS, indirect=True) @pytest.mark.parametrize('config', TEST_CONFIGS, indirect=True)
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_gpio_wakeup_enable_lightsleep(dut: tuple[IdfDut, IdfDut]) -> None: def test_gpio_wakeup_enable_lightsleep(dut: tuple[IdfDut, IdfDut]) -> None:
wakee = dut[0] wakee = dut[0]
waker = dut[1] waker = dut[1]
@@ -14,6 +14,7 @@ from pytest_embedded_idf.utils import idf_parametrize
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_spi_lcd(dut: Dut) -> None: def test_spi_lcd(dut: Dut) -> None:
dut.run_all_single_board_cases() dut.run_all_single_board_cases()
@@ -27,6 +28,7 @@ def test_spi_lcd(dut: Dut) -> None:
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_spi_lcd_with_virt_flash_enc(dut: Dut) -> None: def test_spi_lcd_with_virt_flash_enc(dut: Dut) -> None:
print(' - Erase flash') print(' - Erase flash')
dut.serial.erase_flash() dut.serial.erase_flash()
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2024-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2024-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -17,6 +17,7 @@ from pytest_embedded_idf.utils import idf_parametrize
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_esp_pm(dut: Dut) -> None: def test_esp_pm(dut: Dut) -> None:
dut.run_all_single_board_cases() dut.run_all_single_board_cases()
@@ -8,7 +8,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize( @idf_parametrize(
'target', 'target',
['esp32c3', 'esp32s2', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32p4'], ['esp32c3', 'esp32s2', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32p4', 'esp32s31'],
indirect=['target'], indirect=['target'],
) )
def test_esp_rom(dut: Dut) -> None: def test_esp_rom(dut: Dut) -> None:
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0 # SPDX-License-Identifier: CC0-1.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -14,6 +14,7 @@ from pytest_embedded_idf.utils import idf_parametrize
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
@pytest.mark.temp_skip_ci(targets=['esp32p4'], reason='p4 rev3 migration # TODO: IDF-14421') @pytest.mark.temp_skip_ci(targets=['esp32p4'], reason='p4 rev3 migration # TODO: IDF-14421')
def test_pthread(dut: Dut) -> None: def test_pthread(dut: Dut) -> None:
dut.run_all_single_board_cases(group='!thread-specific', timeout=300) dut.run_all_single_board_cases(group='!thread-specific', timeout=300)
@@ -36,6 +37,7 @@ def test_pthread_single_core(dut: Dut) -> None:
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_pthread_tls(dut: Dut) -> None: def test_pthread_tls(dut: Dut) -> None:
dut.run_all_single_board_cases(group='thread-specific', timeout=300) dut.run_all_single_board_cases(group='thread-specific', timeout=300)
@@ -17,6 +17,7 @@ from pytest_embedded_idf.utils import idf_parametrize
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_esp_flash(dut: Dut) -> None: def test_esp_flash(dut: Dut) -> None:
dut.run_all_single_board_cases(group='esp_flash') dut.run_all_single_board_cases(group='esp_flash')
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -14,6 +14,7 @@ from pytest_embedded_idf.utils import idf_parametrize
indirect=True, indirect=True,
) )
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_esp_flash_stress(dut: Dut) -> None: def test_esp_flash_stress(dut: Dut) -> None:
dut.run_all_single_board_cases(group='esp_flash') dut.run_all_single_board_cases(group='esp_flash')
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
+3 -2
View File
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0 # SPDX-License-Identifier: CC0-1.0
import logging import logging
import os import os
@@ -10,8 +10,9 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_blink(dut: IdfDut) -> None: def test_blink(dut: IdfDut) -> None:
# check and log bin size # check and log bin size
binary_file = os.path.join(dut.app.binary_path, 'blink.bin') binary_file = os.path.join(dut.app.binary_path, 'blink.bin')
bin_size = os.path.getsize(binary_file) bin_size = os.path.getsize(binary_file)
logging.info('blink_bin_size : {}KB'.format(bin_size // 1024)) logging.info(f'blink_bin_size : {bin_size // 1024}KB')
@@ -6,7 +6,9 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('target', ['esp32', 'esp32s3', 'esp32c6', 'esp32c5', 'esp32h2', 'esp32p4'], indirect=['target']) @idf_parametrize(
'target', ['esp32', 'esp32s3', 'esp32c6', 'esp32c5', 'esp32h2', 'esp32p4', 'esp32s31'], indirect=['target']
)
def test_hc_sr04_example(dut: Dut) -> None: def test_hc_sr04_example(dut: Dut) -> None:
dut.expect_exact('example: Install capture timer') dut.expect_exact('example: Install capture timer')
dut.expect_exact('example: Install capture channel') dut.expect_exact('example: Install capture channel')
@@ -6,7 +6,9 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('target', ['esp32', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4'], indirect=['target']) @idf_parametrize(
'target', ['esp32', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4', 'esp32s31'], indirect=['target']
)
def test_servo_mg996r_example(dut: Dut) -> None: def test_servo_mg996r_example(dut: Dut) -> None:
dut.expect_exact('example: Create timer and operator') dut.expect_exact('example: Create timer and operator')
dut.expect_exact('example: Connect timer and operator') dut.expect_exact('example: Connect timer and operator')
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2021-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2021-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0 # SPDX-License-Identifier: CC0-1.0
import itertools import itertools
@@ -11,9 +11,9 @@ from pytest_embedded_idf.utils import idf_parametrize
@idf_parametrize( @idf_parametrize(
'config,target', 'config,target',
itertools.chain( itertools.chain(
itertools.product(['gpio'], ['esp32', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4']), itertools.product(['gpio'], ['esp32', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4', 'esp32s31']),
itertools.product(['tez'], ['esp32', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4']), itertools.product(['tez'], ['esp32', 'esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4', 'esp32s31']),
itertools.product(['soft'], ['esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4']), itertools.product(['soft'], ['esp32s3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4', 'esp32s31']),
), ),
indirect=['config', 'target'], indirect=['config', 'target'],
) )
@@ -8,7 +8,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize( @idf_parametrize(
'target', 'target',
['esp32', 'esp32s2', 'esp32s3', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4'], ['esp32', 'esp32s2', 'esp32s3', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4', 'esp32s31'],
indirect=['target'], indirect=['target'],
) )
def test_sdm_dac_example(dut: Dut) -> None: def test_sdm_dac_example(dut: Dut) -> None:
@@ -8,7 +8,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize( @idf_parametrize(
'target', 'target',
['esp32', 'esp32s2', 'esp32s3', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4'], ['esp32', 'esp32s2', 'esp32s3', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32h2', 'esp32p4', 'esp32s31'],
indirect=['target'], indirect=['target'],
) )
def test_sdm_led_example(dut: Dut) -> None: def test_sdm_led_example(dut: Dut) -> None:
@@ -8,7 +8,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize( @idf_parametrize(
'target', 'target',
['esp32', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32s2', 'esp32s3', 'esp32p4'], ['esp32', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32s2', 'esp32s3', 'esp32p4', 'esp32s31'],
indirect=['target'], indirect=['target'],
) )
def test_gptimer_wiegand(dut: Dut) -> None: def test_gptimer_wiegand(dut: Dut) -> None:
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2023-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2023-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Unlicense OR CC0-1.0 # SPDX-License-Identifier: Unlicense OR CC0-1.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -9,6 +9,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@pytest.mark.parametrize('config', ['spiflash'], indirect=True) @pytest.mark.parametrize('config', ['spiflash'], indirect=True)
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_examples_perf_benchmark_spiflash(dut: Dut) -> None: def test_examples_perf_benchmark_spiflash(dut: Dut) -> None:
# SPI flash # SPI flash
dut.expect('example: Mountig WL layer...', timeout=10) dut.expect('example: Mountig WL layer...', timeout=10)
+4
View File
@@ -305,3 +305,7 @@ examples/system/xip_from_psram:
disable: disable:
- if: IDF_TARGET == "esp32" - if: IDF_TARGET == "esp32"
reason: target esp32 doesn't support this feature. reason: target esp32 doesn't support this feature.
disable_test:
- if: IDF_TARGET == "esp32s31"
temporary: true
reason: cannot pass # TODO: IDF-15526
@@ -66,6 +66,7 @@ def test_examples_app_trace_basic_usj(openocd_dut: 'OpenOCD', dut: IdfDut) -> No
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('config', ['apptrace_uart'], indirect=['config']) @idf_parametrize('config', ['apptrace_uart'], indirect=['config'])
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_examples_app_trace_basic_uart(dut: IdfDut) -> None: def test_examples_app_trace_basic_uart(dut: IdfDut) -> None:
dut.serial.close() dut.serial.close()
with serial.Serial(dut.serial.port, baudrate=1000000, timeout=3) as ser: with serial.Serial(dut.serial.port, baudrate=1000000, timeout=3) as ser:
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0 # SPDX-License-Identifier: CC0-1.0
import logging import logging
import time import time
@@ -12,6 +12,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@idf_parametrize( @idf_parametrize(
'config,target', [('esp32_singlecore', 'esp32'), ('basic', 'supported_targets')], indirect=['config', 'target'] 'config,target', [('esp32_singlecore', 'esp32'), ('basic', 'supported_targets')], indirect=['config', 'target']
) )
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_deep_sleep(dut: Dut) -> None: def test_deep_sleep(dut: Dut) -> None:
dut.expect_exact('Enabling timer wakeup, 20s', timeout=10) dut.expect_exact('Enabling timer wakeup, 20s', timeout=10)
dut.expect_exact('Not a deep sleep reset') dut.expect_exact('Not a deep sleep reset')
@@ -22,7 +23,7 @@ def test_deep_sleep(dut: Dut) -> None:
dut.expect_exact('boot: ESP-IDF') # first output that's the same on all chips dut.expect_exact('boot: ESP-IDF') # first output that's the same on all chips
sleep_time = time.time() - start_sleep sleep_time = time.time() - start_sleep
logging.info('Host measured sleep time at {:.2f}s'.format(sleep_time)) logging.info(f'Host measured sleep time at {sleep_time:.2f}s')
assert 18 < sleep_time < 22 # note: high tolerance as measuring time on the host may have some timing skew assert 18 < sleep_time < 22 # note: high tolerance as measuring time on the host may have some timing skew
dut.expect_exact('boot: Fast booting app from partition', timeout=2) dut.expect_exact('boot: Fast booting app from partition', timeout=2)
+1
View File
@@ -200,5 +200,6 @@ def _test_gcov_uart(dut: IdfDut) -> None:
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('config', ['gcov_uart'], indirect=['config']) @idf_parametrize('config', ['gcov_uart'], indirect=['config'])
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_gcov_uart(dut: IdfDut) -> None: def test_gcov_uart(dut: IdfDut) -> None:
_test_gcov_uart(dut) _test_gcov_uart(dut)
@@ -10,6 +10,7 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_light_sleep(dut: Dut) -> None: def test_light_sleep(dut: Dut) -> None:
ENTERING_SLEEP_STR = 'Entering light sleep' ENTERING_SLEEP_STR = 'Entering light sleep'
EXIT_SLEEP_REGEX = r'Returned from light sleep, reason: (\w+), t=(\d+) ms, slept for (\d+) ms' EXIT_SLEEP_REGEX = r'Returned from light sleep, reason: (\w+), t=(\d+) ms, slept for (\d+) ms'
@@ -159,6 +159,7 @@ def _test_sysview_tracing_uart(dut: IdfDut) -> None:
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize('config', ['sysview_uart'], indirect=['config']) @idf_parametrize('config', ['sysview_uart'], indirect=['config'])
@idf_parametrize('target', ['supported_targets'], indirect=['target']) @idf_parametrize('target', ['supported_targets'], indirect=['target'])
@pytest.mark.temp_skip_ci(targets=['esp32s31'], reason='s31 bringup on this module is not done')
def test_sysview_tracing_uart(dut: IdfDut) -> None: def test_sysview_tracing_uart(dut: IdfDut) -> None:
_test_sysview_tracing_uart(dut) _test_sysview_tracing_uart(dut)
@@ -26,4 +26,3 @@ no_runner_tags:
- esp32h2,jtag - esp32h2,jtag
- esp32p4,jtag - esp32p4,jtag
- esp32s2,usb_host_flash_disk - esp32s2,usb_host_flash_disk
- esp32s31,generic,rev_default # TODO: IDF-14694
+1
View File
@@ -15,6 +15,7 @@ SUPPORTED_TARGETS = [
'esp32p4', 'esp32p4',
'esp32c5', 'esp32c5',
'esp32c61', 'esp32c61',
'esp32s31',
] ]
PREVIEW_TARGETS: list[str] = [] # this PREVIEW_TARGETS excludes 'linux' target PREVIEW_TARGETS: list[str] = [] # this PREVIEW_TARGETS excludes 'linux' target
+5 -1
View File
@@ -76,7 +76,7 @@ tools/test_apps/system/g1_components:
tools/test_apps/system/gdb: tools/test_apps/system/gdb:
disable_test: disable_test:
- if: IDF_TARGET in ["esp32p4", "esp32c5", "esp32c61"] - if: IDF_TARGET in ["esp32p4", "esp32c5", "esp32c61", "esp32s31"]
temporary: true temporary: true
reason: not supported yet # TODO: IDF-13142 reason: not supported yet # TODO: IDF-13142
@@ -149,6 +149,10 @@ tools/test_apps/system/ram_loadable_app:
- if: IDF_TARGET == "esp32p4" - if: IDF_TARGET == "esp32p4"
temporary: true temporary: true
reason: p4 rev3 migration # TODO: IDF-14370 reason: p4 rev3 migration # TODO: IDF-14370
disable_test:
- if: IDF_TARGET == "esp32s31"
temporary: true
reason: cannot pass # TODO: IDF-15525
tools/test_apps/system/rtc_mem_reserve: tools/test_apps/system/rtc_mem_reserve:
enable: enable:
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2024-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2024-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0 # SPDX-License-Identifier: CC0-1.0
import pytest import pytest
from pytest_embedded import Dut from pytest_embedded import Dut
@@ -7,7 +7,9 @@ from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize( @idf_parametrize(
'target', ['esp32c2', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32p4'], indirect=['target'] 'target',
['esp32c2', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32p4', 'esp32s31'],
indirect=['target'],
) )
def test_eh_frame_wdt(dut: Dut) -> None: def test_eh_frame_wdt(dut: Dut) -> None:
dut.expect_exact('Press ENTER to see the list of tests') dut.expect_exact('Press ENTER to see the list of tests')
@@ -19,7 +21,9 @@ def test_eh_frame_wdt(dut: Dut) -> None:
@pytest.mark.generic @pytest.mark.generic
@idf_parametrize( @idf_parametrize(
'target', ['esp32c2', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32p4'], indirect=['target'] 'target',
['esp32c2', 'esp32c3', 'esp32c5', 'esp32c6', 'esp32c61', 'esp32h2', 'esp32p4', 'esp32s31'],
indirect=['target'],
) )
def test_eh_frame_panic(dut: Dut) -> None: def test_eh_frame_panic(dut: Dut) -> None:
dut.expect_exact('Press ENTER to see the list of tests') dut.expect_exact('Press ENTER to see the list of tests')
+12 -8
View File
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD # SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: Unlicense OR CC0-1.0 # SPDX-License-Identifier: Unlicense OR CC0-1.0
import os import os
import re import re
@@ -21,13 +21,17 @@ def _test_idf_gdb(openocd_dut: 'OpenOCD', dut: IdfDut) -> None:
# Don't need to have output from UART anymore # Don't need to have output from UART anymore
dut.serial.stop_redirect_thread() dut.serial.stop_redirect_thread()
with openocd_dut.run(), open(os.path.join(dut.logdir, 'gdb.txt'), 'w') as gdb_log, pexpect.spawn( with (
f'idf.py -B {dut.app.binary_path} gdb --batch', openocd_dut.run(),
timeout=60, open(os.path.join(dut.logdir, 'gdb.txt'), 'w') as gdb_log,
logfile=gdb_log, pexpect.spawn(
encoding='utf-8', f'idf.py -B {dut.app.binary_path} gdb --batch',
codec_errors='ignore', timeout=60,
) as p: logfile=gdb_log,
encoding='utf-8',
codec_errors='ignore',
) as p,
):
p.expect(re.compile(r'add symbol table from file.*bootloader.elf')) p.expect(re.compile(r'add symbol table from file.*bootloader.elf'))
p.expect( p.expect(
re.compile(r'add symbol table from file.*rom.elf') re.compile(r'add symbol table from file.*rom.elf')
+19 -1
View File
@@ -55,7 +55,25 @@ CONFIGS_UBSAN = list(
) )
) )
CONFIG_PANIC = list(itertools.chain(itertools.product(['panic'], ['supported_targets']))) CONFIG_PANIC = list(
itertools.chain(
itertools.product(
['panic'],
[
'esp32',
'esp32c2',
'esp32c3',
'esp32s2',
'esp32s3',
'esp32p4',
'esp32c5',
'esp32c6',
'esp32c61',
'esp32h2',
],
)
)
)
CONFIG_PANIC_DUAL_CORE = list(itertools.chain(itertools.product(['panic'], TARGETS_DUAL_CORE))) CONFIG_PANIC_DUAL_CORE = list(itertools.chain(itertools.product(['panic'], TARGETS_DUAL_CORE)))
CONFIG_PANIC_HALT = list(itertools.chain(itertools.product(['panic_halt'], TARGETS_ALL))) CONFIG_PANIC_HALT = list(itertools.chain(itertools.product(['panic_halt'], TARGETS_ALL)))