From 21c2cd86168436aed260bf44e2cab65b1f71f661 Mon Sep 17 00:00:00 2001 From: Fu Hanxi Date: Fri, 24 Mar 2023 11:51:23 +0800 Subject: [PATCH 1/2] ci: skip build default app if config rules matched, add missing files --- components/esp_wifi/test_apps/wifi_connect/sdkconfig.ci | 0 components/esp_wifi/test_apps/wifi_function/sdkconfig.ci | 0 examples/peripherals/adc/oneshot_read/sdkconfig.ci | 0 3 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 components/esp_wifi/test_apps/wifi_connect/sdkconfig.ci create mode 100644 components/esp_wifi/test_apps/wifi_function/sdkconfig.ci create mode 100644 examples/peripherals/adc/oneshot_read/sdkconfig.ci diff --git a/components/esp_wifi/test_apps/wifi_connect/sdkconfig.ci b/components/esp_wifi/test_apps/wifi_connect/sdkconfig.ci new file mode 100644 index 0000000000..e69de29bb2 diff --git a/components/esp_wifi/test_apps/wifi_function/sdkconfig.ci b/components/esp_wifi/test_apps/wifi_function/sdkconfig.ci new file mode 100644 index 0000000000..e69de29bb2 diff --git a/examples/peripherals/adc/oneshot_read/sdkconfig.ci b/examples/peripherals/adc/oneshot_read/sdkconfig.ci new file mode 100644 index 0000000000..e69de29bb2 From 08df42ae06a2b28236357e28dbad8af05452242b Mon Sep 17 00:00:00 2001 From: Fu Hanxi Date: Fri, 24 Mar 2023 11:51:55 +0800 Subject: [PATCH 2/2] ci: sdkconfig.ci.xxx.TARGET now have correct config name xxx --- .../efuse/pytest_system_efuse_example.py | 163 +++--------------- .../efuse/sdkconfig.ci.virt_sb_v2_and_fe | 0 .../efuse/sdkconfig.ci.virt_secure_boot_v2 | 0 3 files changed, 23 insertions(+), 140 deletions(-) create mode 100644 examples/system/efuse/sdkconfig.ci.virt_sb_v2_and_fe create mode 100644 examples/system/efuse/sdkconfig.ci.virt_secure_boot_v2 diff --git a/examples/system/efuse/pytest_system_efuse_example.py b/examples/system/efuse/pytest_system_efuse_example.py index ec404dcb53..aa3c557d8c 100644 --- a/examples/system/efuse/pytest_system_efuse_example.py +++ b/examples/system/efuse/pytest_system_efuse_example.py @@ -370,7 +370,7 @@ def test_examples_efuse_with_virt_secure_boot_v1_pre_loaded(dut: Dut) -> None: @pytest.mark.esp32 @pytest.mark.esp32eco3 -@pytest.mark.parametrize('config', [('virt_secure_boot_v2.esp32'),], indirect=True) +@pytest.mark.parametrize('config', [('virt_secure_boot_v2'),], indirect=True) @pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) def test_examples_efuse_with_virt_secure_boot_v2(dut: Dut) -> None: # only for ESP32 ECO3 @@ -486,7 +486,7 @@ def test_examples_efuse_with_virt_secure_boot_v2(dut: Dut) -> None: @pytest.mark.esp32 @pytest.mark.esp32eco3 -@pytest.mark.parametrize('config', [('virt_secure_boot_v2.esp32'),], indirect=True) +@pytest.mark.parametrize('config', [('virt_secure_boot_v2'),], indirect=True) @pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) def test_examples_efuse_with_virt_secure_boot_v2_pre_loaded(dut: Dut) -> None: @@ -549,6 +549,15 @@ def test_examples_efuse_with_virt_secure_boot_v2_pre_loaded(dut: Dut) -> None: dut.expect('example: Done') +@pytest.mark.esp32c3 +@pytest.mark.esp32c2 +@pytest.mark.esp32c6 +@pytest.mark.esp32h2 +@pytest.mark.esp32s2 +@pytest.mark.esp32s3 +@pytest.mark.generic +@pytest.mark.parametrize('config', ['virt_secure_boot_v2'], indirect=True) +@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) def test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut: Dut) -> None: # check and log bin size binary_file = os.path.join(dut.app.binary_path, 'bootloader', 'bootloader.bin') @@ -612,54 +621,15 @@ def test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut: Dut) -> None: dut.expect('example: Done') -@pytest.mark.generic @pytest.mark.esp32c3 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32c3'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32c3(dut: Dut) -> None: - test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut) - - -@pytest.mark.generic @pytest.mark.esp32c2 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32c2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32c2(dut: Dut) -> None: - test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut) - - -@pytest.mark.generic @pytest.mark.esp32c6 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32c6'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32c6(dut: Dut) -> None: - test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut) - - -@pytest.mark.generic @pytest.mark.esp32h2 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32h2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32h2(dut: Dut) -> None: - test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut) - - -@pytest.mark.generic @pytest.mark.esp32s2 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32s2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32s2(dut: Dut) -> None: - test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut) - - -@pytest.mark.generic @pytest.mark.esp32s3 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32s3'], indirect=True) +@pytest.mark.generic +@pytest.mark.parametrize('config', ['virt_secure_boot_v2'], indirect=True) @pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32s3(dut: Dut) -> None: - test_examples_efuse_with_virt_secure_boot_v2_esp32xx(dut) - - def test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut: Dut) -> None: print(' - Erase flash') dut.serial.erase_flash() @@ -728,54 +698,6 @@ def test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut: Dut) -> dut.expect('example: Done') -@pytest.mark.generic -@pytest.mark.esp32c3 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32c3'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32c3_pre_loaded(dut: Dut) -> None: - test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut) - - -@pytest.mark.generic -@pytest.mark.esp32c2 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32c2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32c2_pre_loaded(dut: Dut) -> None: - test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut) - - -@pytest.mark.generic -@pytest.mark.esp32c6 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32c6'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32c6_pre_loaded(dut: Dut) -> None: - test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut) - - -@pytest.mark.generic -@pytest.mark.esp32h2 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32h2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32h2_pre_loaded(dut: Dut) -> None: - test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut) - - -@pytest.mark.generic -@pytest.mark.esp32s2 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32s2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32s2_pre_loaded(dut: Dut) -> None: - test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut) - - -@pytest.mark.generic -@pytest.mark.esp32s3 -@pytest.mark.parametrize('config', ['virt_secure_boot_v2.esp32s3'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_secure_boot_v2_esp32s3_pre_loaded(dut: Dut) -> None: - test_example_efuse_with_virt_secure_boot_v2_esp32xx_pre_loaded(dut) - - @pytest.mark.generic @pytest.mark.esp32 @pytest.mark.parametrize('config', ['virt_sb_v1_and_fe',], indirect=True) @@ -843,7 +765,7 @@ def test_examples_efuse_with_virt_sb_v1_and_fe(dut: Dut) -> None: @pytest.mark.esp32 @pytest.mark.esp32eco3 -@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe.esp32',], indirect=True) +@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe',], indirect=True) @pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) def test_examples_efuse_with_virt_sb_v2_and_fe(dut: Dut) -> None: # check and log bin size @@ -923,6 +845,15 @@ def test_examples_efuse_with_virt_sb_v2_and_fe(dut: Dut) -> None: dut.expect('example: Done') +@pytest.mark.esp32c3 +@pytest.mark.esp32c2 +@pytest.mark.esp32c6 +@pytest.mark.esp32h2 +@pytest.mark.esp32s2 +@pytest.mark.esp32s3 +@pytest.mark.generic +@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) +@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe'], indirect=True) def test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut: Dut) -> None: # check and log bin size binary_file = os.path.join(dut.app.binary_path, 'bootloader', 'bootloader.bin') @@ -1011,51 +942,3 @@ def test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut: Dut) -> None: dut.expect('example: Flash Encryption is NOT in RELEASE mode') dut.expect('example: Secure Boot is in RELEASE mode') dut.expect('example: Done') - - -@pytest.mark.generic -@pytest.mark.esp32c3 -@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe.esp32c3'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_sb_v2_and_fe_esp32c3(dut: Dut) -> None: - test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut) - - -@pytest.mark.generic -@pytest.mark.esp32c2 -@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe.esp32c2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_sb_v2_and_fe_esp32c2(dut: Dut) -> None: - test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut) - - -@pytest.mark.generic -@pytest.mark.esp32c6 -@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe.esp32c6'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_sb_v2_and_fe_esp32c6(dut: Dut) -> None: - test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut) - - -@pytest.mark.generic -@pytest.mark.esp32h2 -@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe.esp32h2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_sb_v2_and_fe_esp32h2(dut: Dut) -> None: - test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut) - - -@pytest.mark.generic -@pytest.mark.esp32s2 -@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe.esp32s2'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_sb_v2_and_fe_esp32s2(dut: Dut) -> None: - test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut) - - -@pytest.mark.generic -@pytest.mark.esp32s3 -@pytest.mark.parametrize('config', ['virt_sb_v2_and_fe.esp32s3'], indirect=True) -@pytest.mark.parametrize('skip_autoflash', ['y'], indirect=True) -def test_examples_efuse_with_virt_sb_v2_and_fe_esp32s3(dut: Dut) -> None: - test_examples_efuse_with_virt_sb_v2_and_fe_esp32xx(dut) diff --git a/examples/system/efuse/sdkconfig.ci.virt_sb_v2_and_fe b/examples/system/efuse/sdkconfig.ci.virt_sb_v2_and_fe new file mode 100644 index 0000000000..e69de29bb2 diff --git a/examples/system/efuse/sdkconfig.ci.virt_secure_boot_v2 b/examples/system/efuse/sdkconfig.ci.virt_secure_boot_v2 new file mode 100644 index 0000000000..e69de29bb2