Skip to content

Commit 03e344d

Browse files
committed
test(flash_mmap): added psram enabled test for esp32p4 as mmu is per target
1 parent 253fc4f commit 03e344d

File tree

3 files changed

+16
-1
lines changed

3 files changed

+16
-1
lines changed

components/spi_flash/test_apps/.build-test-rules.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ components/spi_flash/test_apps/flash_mmap:
3232
- spi_flash
3333
enable:
3434
- if: CONFIG_NAME in ["release", "rom_impl"] and IDF_TARGET != "linux"
35+
- if: CONFIG_NAME == "psram" and SOC_MMU_PER_EXT_MEM_TARGET == 1 # MMU per target needs test. On unified MMU chips, the entry ID is unique
3536
- if: CONFIG_NAME == "xip_psram" and IDF_TARGET in ["esp32s2", "esp32s3", "esp32p4"]
3637
# S2 doesn't have ROM for flash
3738
- if: CONFIG_NAME == "xip_psram_with_rom_impl" and IDF_TARGET in ["esp32s3", "esp32p4"]

components/spi_flash/test_apps/flash_mmap/pytest_flash_mmap.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
1+
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
22
# SPDX-License-Identifier: Apache-2.0
33
import pytest
44
from pytest_embedded import Dut
@@ -47,6 +47,19 @@ def test_flash_mmap_xip_psram(dut: Dut) -> None:
4747
dut.run_all_single_board_cases(timeout=30)
4848

4949

50+
@pytest.mark.supported_targets
51+
@pytest.mark.generic
52+
@pytest.mark.parametrize(
53+
'config',
54+
[
55+
'psram',
56+
],
57+
indirect=True,
58+
)
59+
def test_flash_mmap_psram(dut: Dut) -> None:
60+
dut.run_all_single_board_cases(timeout=30)
61+
62+
5063
@pytest.mark.supported_targets
5164
@pytest.mark.generic
5265
@pytest.mark.parametrize(
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
CONFIG_SPIRAM=y

0 commit comments

Comments
 (0)