kopia lustrzana https://github.com/espressif/esp-idf
feat(storage): minimize platforms for tests
rodzic
8f3abfb60e
commit
559fb2d2bf
|
@ -2,10 +2,11 @@
|
||||||
|
|
||||||
examples/storage/custom_flash_driver:
|
examples/storage/custom_flash_driver:
|
||||||
depends_components:
|
depends_components:
|
||||||
- fatfs
|
|
||||||
- vfs
|
|
||||||
- spi_flash
|
- spi_flash
|
||||||
- driver
|
- driver
|
||||||
|
disable_test:
|
||||||
|
- if: IDF_TARGET not in ["esp32", "esp32c3"]
|
||||||
|
reason: only one target per arch needed
|
||||||
|
|
||||||
examples/storage/emmc:
|
examples/storage/emmc:
|
||||||
depends_components:
|
depends_components:
|
||||||
|
@ -23,12 +24,11 @@ examples/storage/ext_flash_fatfs:
|
||||||
- vfs
|
- vfs
|
||||||
- spi_flash
|
- spi_flash
|
||||||
- driver
|
- driver
|
||||||
- esp_system
|
|
||||||
disable:
|
disable:
|
||||||
- if: IDF_TARGET == "esp32p4"
|
- if: IDF_TARGET == "esp32p4"
|
||||||
reason: not supported yet
|
reason: not supported yet
|
||||||
disable_test:
|
disable_test:
|
||||||
- if: IDF_TARGET not in ["esp32", "esp32s2"]
|
- if: IDF_TARGET not in ["esp32"]
|
||||||
temporary: true
|
temporary: true
|
||||||
reason: lack of runners
|
reason: lack of runners
|
||||||
|
|
||||||
|
@ -36,7 +36,6 @@ examples/storage/fatfsgen:
|
||||||
depends_components:
|
depends_components:
|
||||||
- fatfs
|
- fatfs
|
||||||
- vfs
|
- vfs
|
||||||
- esp_system
|
|
||||||
disable_test:
|
disable_test:
|
||||||
- if: IDF_TARGET != "esp32"
|
- if: IDF_TARGET != "esp32"
|
||||||
reason: only one target needed
|
reason: only one target needed
|
||||||
|
@ -45,17 +44,23 @@ examples/storage/nvs_rw_blob:
|
||||||
depends_components:
|
depends_components:
|
||||||
- nvs_flash
|
- nvs_flash
|
||||||
- driver
|
- driver
|
||||||
- esp_system
|
disable_test:
|
||||||
|
- if: IDF_TARGET not in ["esp32", "esp32c3"]
|
||||||
|
reason: only one target per arch needed
|
||||||
|
|
||||||
examples/storage/nvs_rw_value:
|
examples/storage/nvs_rw_value:
|
||||||
depends_components:
|
depends_components:
|
||||||
- nvs_flash
|
- nvs_flash
|
||||||
- nvs_system
|
disable_test:
|
||||||
|
- if: IDF_TARGET not in ["esp32", "esp32c3"]
|
||||||
|
reason: only one target per arch needed
|
||||||
|
|
||||||
examples/storage/nvs_rw_value_cxx:
|
examples/storage/nvs_rw_value_cxx:
|
||||||
depends_components:
|
depends_components:
|
||||||
- nvs_flash
|
- nvs_flash
|
||||||
- nvs_system
|
disable_test:
|
||||||
|
- if: IDF_TARGET not in ["esp32", "esp32c3"]
|
||||||
|
reason: only one target per arch needed
|
||||||
|
|
||||||
examples/storage/nvsgen:
|
examples/storage/nvsgen:
|
||||||
depends_components:
|
depends_components:
|
||||||
|
@ -100,7 +105,6 @@ examples/storage/perf_benchmark:
|
||||||
- vfs
|
- vfs
|
||||||
- sdmmc
|
- sdmmc
|
||||||
- spiffs
|
- spiffs
|
||||||
- soc
|
|
||||||
- wear_levelling
|
- wear_levelling
|
||||||
- esp_partition
|
- esp_partition
|
||||||
- driver
|
- driver
|
||||||
|
@ -133,7 +137,7 @@ examples/storage/sd_card/sdspi:
|
||||||
disable:
|
disable:
|
||||||
- if: SOC_GPSPI_SUPPORTED != 1
|
- if: SOC_GPSPI_SUPPORTED != 1
|
||||||
disable_test:
|
disable_test:
|
||||||
- if: IDF_TARGET not in ["esp32", "esp32c3", "esp32s2"]
|
- if: IDF_TARGET not in ["esp32", "esp32c3"]
|
||||||
temporary: true
|
temporary: true
|
||||||
reason: lack of runners
|
reason: lack of runners
|
||||||
|
|
||||||
|
@ -149,6 +153,9 @@ examples/storage/spiffs:
|
||||||
depends_components:
|
depends_components:
|
||||||
- spiffs
|
- spiffs
|
||||||
- vfs
|
- vfs
|
||||||
|
disable_test:
|
||||||
|
- if: IDF_TARGET not in ["esp32", "esp32c3"]
|
||||||
|
reason: only one target per arch needed
|
||||||
|
|
||||||
examples/storage/spiffsgen:
|
examples/storage/spiffsgen:
|
||||||
depends_components:
|
depends_components:
|
||||||
|
@ -164,3 +171,6 @@ examples/storage/wear_levelling:
|
||||||
- vfs
|
- vfs
|
||||||
- wear_levelling
|
- wear_levelling
|
||||||
- fatfs
|
- fatfs
|
||||||
|
disable_test:
|
||||||
|
- if: IDF_TARGET not in ["esp32", "esp32c3"]
|
||||||
|
reason: only one target per arch needed
|
||||||
|
|
|
@ -7,7 +7,6 @@ from pytest_embedded import Dut
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.esp32
|
@pytest.mark.esp32
|
||||||
@pytest.mark.esp32s2
|
|
||||||
@pytest.mark.external_flash
|
@pytest.mark.external_flash
|
||||||
def test_ext_flash_fatfs(dut: Dut) -> None:
|
def test_ext_flash_fatfs(dut: Dut) -> None:
|
||||||
message_list = ('Initialized external Flash',
|
message_list = ('Initialized external Flash',
|
||||||
|
|
|
@ -9,7 +9,6 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include "esp_vfs.h"
|
#include "esp_vfs.h"
|
||||||
#include "esp_vfs_fat.h"
|
#include "esp_vfs_fat.h"
|
||||||
#include "esp_system.h"
|
|
||||||
#include "sdkconfig.h"
|
#include "sdkconfig.h"
|
||||||
|
|
||||||
#if CONFIG_EXAMPLE_FATFS_MODE_READ_ONLY
|
#if CONFIG_EXAMPLE_FATFS_MODE_READ_ONLY
|
||||||
|
|
|
@ -11,7 +11,8 @@ import pytest
|
||||||
from pytest_embedded import Dut
|
from pytest_embedded import Dut
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.esp32
|
||||||
|
@pytest.mark.esp32c3
|
||||||
def test_examples_nvs_rw_blob(dut: Dut) -> None:
|
def test_examples_nvs_rw_blob(dut: Dut) -> None:
|
||||||
def expect_start_msg(index: int) -> None:
|
def expect_start_msg(index: int) -> None:
|
||||||
dut.expect('Restart counter = {}'.format(index), timeout=10)
|
dut.expect('Restart counter = {}'.format(index), timeout=10)
|
||||||
|
|
|
@ -8,7 +8,8 @@ import pytest
|
||||||
from pytest_embedded import Dut
|
from pytest_embedded import Dut
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.esp32
|
||||||
|
@pytest.mark.esp32c3
|
||||||
def test_examples_nvs_rw_value(dut: Dut) -> None:
|
def test_examples_nvs_rw_value(dut: Dut) -> None:
|
||||||
for i, counter_state in zip_longest(range(4), ('The value is not initialized yet!',), fillvalue='Done'):
|
for i, counter_state in zip_longest(range(4), ('The value is not initialized yet!',), fillvalue='Done'):
|
||||||
dut.expect('Opening Non-Volatile Storage \\(NVS\\) handle... Done', timeout=20)
|
dut.expect('Opening Non-Volatile Storage \\(NVS\\) handle... Done', timeout=20)
|
||||||
|
|
|
@ -8,7 +8,8 @@ import pytest
|
||||||
from pytest_embedded import Dut
|
from pytest_embedded import Dut
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.esp32
|
||||||
|
@pytest.mark.esp32c3
|
||||||
def test_examples_nvs_rw_value_cxx(dut: Dut) -> None:
|
def test_examples_nvs_rw_value_cxx(dut: Dut) -> None:
|
||||||
for i, counter_state in zip_longest(range(4), ('The value is not initialized yet!',), fillvalue='Done'):
|
for i, counter_state in zip_longest(range(4), ('The value is not initialized yet!',), fillvalue='Done'):
|
||||||
dut.expect('Opening Non-Volatile Storage \\(NVS\\) handle... Done', timeout=20)
|
dut.expect('Opening Non-Volatile Storage \\(NVS\\) handle... Done', timeout=20)
|
||||||
|
|
|
@ -11,7 +11,6 @@ from pytest_embedded import Dut
|
||||||
|
|
||||||
@pytest.mark.esp32
|
@pytest.mark.esp32
|
||||||
@pytest.mark.esp32c3 # no runner available at the moment
|
@pytest.mark.esp32c3 # no runner available at the moment
|
||||||
@pytest.mark.esp32s2
|
|
||||||
@pytest.mark.sdcard_spimode
|
@pytest.mark.sdcard_spimode
|
||||||
def test_examples_sd_card_sdspi(dut: Dut) -> None:
|
def test_examples_sd_card_sdspi(dut: Dut) -> None:
|
||||||
dut.expect('example: Initializing SD card', timeout=20)
|
dut.expect('example: Initializing SD card', timeout=20)
|
||||||
|
|
|
@ -34,30 +34,6 @@ def prepare() -> t.Generator[None, None, None]:
|
||||||
f'-c \'set ESP_SEMIHOST_BASEDIR "{TEMP_DIR}"\' -f board/esp32-wrover-kit-3.3v.cfg',
|
f'-c \'set ESP_SEMIHOST_BASEDIR "{TEMP_DIR}"\' -f board/esp32-wrover-kit-3.3v.cfg',
|
||||||
marks=[pytest.mark.esp32],
|
marks=[pytest.mark.esp32],
|
||||||
),
|
),
|
||||||
# pytest.param(
|
|
||||||
# 'esp,idf,jtag',
|
|
||||||
# 'y',
|
|
||||||
# f'-c \'set ESP_SEMIHOST_BASEDIR "{TEMP_DIR}"\' -f board/esp32c2-ftdi.cfg',
|
|
||||||
# marks=[pytest.mark.esp32c2],
|
|
||||||
# ),
|
|
||||||
# pytest.param(
|
|
||||||
# 'esp,idf,jtag',
|
|
||||||
# 'y',
|
|
||||||
# f'-c \'set ESP_SEMIHOST_BASEDIR "{TEMP_DIR}"\' -f board/esp32s2-kaluga-1.cfg',
|
|
||||||
# marks=[pytest.mark.esp32c3],
|
|
||||||
# ),
|
|
||||||
# pytest.param(
|
|
||||||
# 'esp,idf,jtag',
|
|
||||||
# 'y',
|
|
||||||
# f'-c \'set ESP_SEMIHOST_BASEDIR "{TEMP_DIR}"\' -f board/esp32s2-kaluga-1.cfg',
|
|
||||||
# marks=[pytest.mark.esp32s2],
|
|
||||||
# ),
|
|
||||||
# pytest.param(
|
|
||||||
# 'esp,idf,jtag',
|
|
||||||
# 'y',
|
|
||||||
# f'-c \'set ESP_SEMIHOST_BASEDIR "{TEMP_DIR}"\' -f board/esp32s2-kaluga-1.cfg',
|
|
||||||
# marks=[pytest.mark.esp32s3],
|
|
||||||
# ),
|
|
||||||
],
|
],
|
||||||
indirect=True,
|
indirect=True,
|
||||||
)
|
)
|
||||||
|
|
|
@ -7,7 +7,8 @@ import pytest
|
||||||
from pytest_embedded import Dut
|
from pytest_embedded import Dut
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.esp32
|
||||||
|
@pytest.mark.esp32c3
|
||||||
def test_examples_spiffs(dut: Dut) -> None:
|
def test_examples_spiffs(dut: Dut) -> None:
|
||||||
message_list = (rb'example: Initializing SPIFFS',
|
message_list = (rb'example: Initializing SPIFFS',
|
||||||
rb'example: Partition size: total: \d+, used: \d+',
|
rb'example: Partition size: total: \d+, used: \d+',
|
||||||
|
|
|
@ -8,7 +8,8 @@ import pytest
|
||||||
from pytest_embedded import Dut
|
from pytest_embedded import Dut
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.esp32
|
||||||
|
@pytest.mark.esp32c3
|
||||||
def test_wear_levelling_example(dut: Dut) -> None:
|
def test_wear_levelling_example(dut: Dut) -> None:
|
||||||
|
|
||||||
message_list = ('example: Mounting FAT filesystem',
|
message_list = ('example: Mounting FAT filesystem',
|
||||||
|
|
Ładowanie…
Reference in New Issue