forked from espressif/esp-idf
Merge branch 'feature/core_c6_component_tests' into 'master'
ci: update idf-core related tests for C6 Closes IDF-6888 See merge request espressif/esp-idf!22282
This commit is contained in:
@@ -6,6 +6,6 @@ components/bootloader_support/test_apps/rtc_custom_section:
|
|||||||
temporary: false
|
temporary: false
|
||||||
reason: esp32c2 does not have RTC memory
|
reason: esp32c2 does not have RTC memory
|
||||||
disable_test:
|
disable_test:
|
||||||
- if: IDF_TARGET == "esp32c6" or IDF_TARGET == "esp32h2"
|
- if: IDF_TARGET == "esp32h2"
|
||||||
temporary: true
|
temporary: true
|
||||||
reason: target esp32c6/esp32h2 is not supported yet
|
reason: target esp32h2 is not supported yet
|
||||||
|
@@ -3,4 +3,11 @@
|
|||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
|
||||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||||
|
|
||||||
|
set(SDKCONFIG_DEFAULTS "$ENV{IDF_PATH}/tools/test_apps/configs/sdkconfig.debug_helpers")
|
||||||
|
list(APPEND SDKCONFIG_DEFAULTS "sdkconfig.defaults")
|
||||||
|
|
||||||
|
# "Trim" the build. Include the minimal set of components, main, and anything it depends on.
|
||||||
|
set(COMPONENTS main)
|
||||||
|
|
||||||
project(test_bootloader_support)
|
project(test_bootloader_support)
|
||||||
|
@@ -1,3 +1,4 @@
|
|||||||
idf_component_register(SRCS "test_app_main.c" "test_verify_image.c"
|
idf_component_register(SRCS "test_app_main.c" "test_verify_image.c"
|
||||||
INCLUDE_DIRS "."
|
INCLUDE_DIRS "."
|
||||||
|
REQUIRES unity bootloader_support esp_partition app_update
|
||||||
WHOLE_ARCHIVE)
|
WHOLE_ARCHIVE)
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
* SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
*
|
*
|
||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
@@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
|
|
||||||
// Some resources are lazy allocated (newlib locks) in the bootloader support code, the threshold is left for that case
|
// Some resources are lazy allocated (newlib locks) in the bootloader support code, the threshold is left for that case
|
||||||
#define TEST_MEMORY_LEAK_THRESHOLD (-550)
|
#define TEST_MEMORY_LEAK_THRESHOLD (-650)
|
||||||
|
|
||||||
static size_t before_free_8bit;
|
static size_t before_free_8bit;
|
||||||
static size_t before_free_32bit;
|
static size_t before_free_32bit;
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
@@ -8,6 +8,4 @@ from pytest_embedded import Dut
|
|||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.supported_targets
|
||||||
def test_bootloader_support(dut: Dut) -> None:
|
def test_bootloader_support(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=300)
|
|
||||||
|
@@ -0,0 +1,3 @@
|
|||||||
|
# This "default" configuration is appended to all other configurations
|
||||||
|
# The contents of "sdkconfig.debug_helpers" is also appended to all other configurations (see CMakeLists.txt)
|
||||||
|
CONFIG_ESP_TASK_WDT_INIT=n
|
@@ -3,4 +3,11 @@
|
|||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
|
||||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||||
|
|
||||||
|
set(SDKCONFIG_DEFAULTS "$ENV{IDF_PATH}/tools/test_apps/configs/sdkconfig.debug_helpers")
|
||||||
|
list(APPEND SDKCONFIG_DEFAULTS "sdkconfig.defaults")
|
||||||
|
|
||||||
|
# "Trim" the build. Include the minimal set of components, main, and anything it depends on.
|
||||||
|
set(COMPONENTS main)
|
||||||
|
|
||||||
project(test_rtc_custom_section)
|
project(test_rtc_custom_section)
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
@@ -8,6 +8,7 @@ from pytest_embedded import Dut
|
|||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.esp32
|
@pytest.mark.esp32
|
||||||
@pytest.mark.esp32c3
|
@pytest.mark.esp32c3
|
||||||
|
@pytest.mark.esp32c6
|
||||||
@pytest.mark.esp32s2
|
@pytest.mark.esp32s2
|
||||||
@pytest.mark.esp32s3
|
@pytest.mark.esp32s3
|
||||||
def test_rtc_reserved_memory(dut: Dut) -> None:
|
def test_rtc_reserved_memory(dut: Dut) -> None:
|
||||||
|
@@ -1,3 +1,6 @@
|
|||||||
|
# The contents of "sdkconfig.debug_helpers" is also appended to all other configurations (see CMakeLists.txt)
|
||||||
|
CONFIG_ESP_TASK_WDT_INIT=n
|
||||||
|
|
||||||
CONFIG_BOOTLOADER_RESERVE_RTC_SIZE=0x10
|
CONFIG_BOOTLOADER_RESERVE_RTC_SIZE=0x10
|
||||||
CONFIG_BOOTLOADER_CUSTOM_RESERVE_RTC=y
|
CONFIG_BOOTLOADER_CUSTOM_RESERVE_RTC=y
|
||||||
CONFIG_BOOTLOADER_CUSTOM_RESERVE_RTC_SIZE=0x200
|
CONFIG_BOOTLOADER_CUSTOM_RESERVE_RTC_SIZE=0x200
|
||||||
|
@@ -2,7 +2,12 @@
|
|||||||
# CMakeLists in this exact order for cmake to work correctly
|
# CMakeLists in this exact order for cmake to work correctly
|
||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
|
||||||
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/tools/unit-test-app/components")
|
|
||||||
|
|
||||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||||
|
|
||||||
|
set(SDKCONFIG_DEFAULTS "$ENV{IDF_PATH}/tools/test_apps/configs/sdkconfig.debug_helpers")
|
||||||
|
list(APPEND SDKCONFIG_DEFAULTS "sdkconfig.defaults")
|
||||||
|
|
||||||
|
# "Trim" the build. Include the minimal set of components, main, and anything it depends on.
|
||||||
|
set(COMPONENTS main)
|
||||||
|
|
||||||
project(test_console)
|
project(test_console)
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
@@ -8,6 +8,4 @@ from pytest_embedded import Dut
|
|||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.supported_targets
|
||||||
def test_console(dut: Dut) -> None:
|
def test_console(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('![ignore]')
|
|
||||||
dut.expect_unity_test_output()
|
|
||||||
|
3
components/console/test_apps/console/sdkconfig.defaults
Normal file
3
components/console/test_apps/console/sdkconfig.defaults
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
# This "default" configuration is appended to all other configurations
|
||||||
|
# The contents of "sdkconfig.debug_helpers" is also appended to all other configurations (see CMakeLists.txt)
|
||||||
|
CONFIG_ESP_TASK_WDT_INIT=n
|
@@ -14,9 +14,7 @@ from pytest_embedded import Dut
|
|||||||
@pytest.mark.esp32h2
|
@pytest.mark.esp32h2
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
def test_efuse(dut: Dut) -> None:
|
def test_efuse(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=200)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.qemu
|
@pytest.mark.qemu
|
||||||
|
@@ -2,7 +2,12 @@
|
|||||||
# CMakeLists in this exact order for cmake to work correctly
|
# CMakeLists in this exact order for cmake to work correctly
|
||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
|
||||||
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/tools/unit-test-app/components")
|
|
||||||
|
|
||||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||||
|
|
||||||
|
set(SDKCONFIG_DEFAULTS "$ENV{IDF_PATH}/tools/test_apps/configs/sdkconfig.debug_helpers")
|
||||||
|
list(APPEND SDKCONFIG_DEFAULTS "sdkconfig.defaults")
|
||||||
|
|
||||||
|
# "Trim" the build. Include the minimal set of components, main, and anything it depends on.
|
||||||
|
set(COMPONENTS main)
|
||||||
|
|
||||||
project(test_esp_common)
|
project(test_esp_common)
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
idf_component_register(SRCS "test_app_main.c" "test_attr.c"
|
idf_component_register(SRCS "test_app_main.c" "test_attr.c"
|
||||||
INCLUDE_DIRS "."
|
INCLUDE_DIRS "."
|
||||||
PRIV_REQUIRES test_utils esp_psram
|
PRIV_REQUIRES unity esp_psram
|
||||||
WHOLE_ARCHIVE)
|
WHOLE_ARCHIVE)
|
||||||
|
@@ -13,7 +13,6 @@
|
|||||||
#if CONFIG_IDF_TARGET_ESP32
|
#if CONFIG_IDF_TARGET_ESP32
|
||||||
#include "esp_private/esp_psram_extram.h"
|
#include "esp_private/esp_psram_extram.h"
|
||||||
#endif
|
#endif
|
||||||
#include "test_utils.h"
|
|
||||||
|
|
||||||
extern int _rtc_noinit_start;
|
extern int _rtc_noinit_start;
|
||||||
extern int _rtc_noinit_end;
|
extern int _rtc_noinit_end;
|
||||||
|
@@ -1,14 +1,9 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
import re
|
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from pytest_embedded import Dut
|
from pytest_embedded import Dut
|
||||||
|
|
||||||
DEFAULT_TIMEOUT = 20
|
|
||||||
TEST_SUBMENU_PATTERN_PYTEST = re.compile(rb'\s+\((\d+)\)\s+"([^"]+)"\r?\n')
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.supported_targets
|
||||||
@@ -19,18 +14,11 @@ TEST_SUBMENU_PATTERN_PYTEST = re.compile(rb'\s+\((\d+)\)\s+"([^"]+)"\r?\n')
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
def test_esp_common(dut: Dut) -> None:
|
def test_esp_common(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=300)
|
|
||||||
|
|
||||||
|
|
||||||
def run_multiple_stages(dut: Dut, test_case_num: int, stages: int) -> None:
|
def run_multiple_stages(dut: Dut, test_case_num: int, stages: int) -> None:
|
||||||
for stage in range(1, stages + 1):
|
dut.run_all_single_board_cases()
|
||||||
dut.write(str(test_case_num))
|
|
||||||
dut.expect(TEST_SUBMENU_PATTERN_PYTEST, timeout=DEFAULT_TIMEOUT)
|
|
||||||
dut.write(str(stage))
|
|
||||||
if stage != stages:
|
|
||||||
dut.expect_exact('Press ENTER to see the list of tests.')
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@@ -42,14 +30,7 @@ def run_multiple_stages(dut: Dut, test_case_num: int, stages: int) -> None:
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
def test_esp_common_psram_esp32(dut: Dut) -> None:
|
def test_esp_common_psram_esp32(dut: Dut) -> None:
|
||||||
extra_data = dut.parse_test_menu()
|
dut.run_all_single_board_cases()
|
||||||
for test_case in extra_data:
|
|
||||||
if test_case.type != 'multi_stage':
|
|
||||||
dut.write(str(test_case.index))
|
|
||||||
else:
|
|
||||||
run_multiple_stages(dut, test_case.index, len(test_case.subcases))
|
|
||||||
dut.expect_unity_test_output(timeout=90)
|
|
||||||
dut.expect_exact("Enter next test, or 'enter' to see menu")
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@@ -61,11 +42,4 @@ def test_esp_common_psram_esp32(dut: Dut) -> None:
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
def test_esp_common_psram_esp32s2(dut: Dut) -> None:
|
def test_esp_common_psram_esp32s2(dut: Dut) -> None:
|
||||||
extra_data = dut.parse_test_menu()
|
dut.run_all_single_board_cases()
|
||||||
for test_case in extra_data:
|
|
||||||
if test_case.type != 'multi_stage':
|
|
||||||
dut.write(str(test_case.index))
|
|
||||||
else:
|
|
||||||
run_multiple_stages(dut, test_case.index, len(test_case.subcases))
|
|
||||||
dut.expect_unity_test_output(timeout=90)
|
|
||||||
dut.expect_exact("Enter next test, or 'enter' to see menu")
|
|
||||||
|
@@ -3,8 +3,13 @@
|
|||||||
# CMakeLists in this exact order for cmake to work correctly
|
# CMakeLists in this exact order for cmake to work correctly
|
||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
|
||||||
|
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||||
|
|
||||||
|
set(SDKCONFIG_DEFAULTS "$ENV{IDF_PATH}/tools/test_apps/configs/sdkconfig.debug_helpers")
|
||||||
|
list(APPEND SDKCONFIG_DEFAULTS "sdkconfig.defaults")
|
||||||
|
|
||||||
|
# "Trim" the build. Include the minimal set of components, main, and anything it depends on.
|
||||||
set(COMPONENTS main)
|
set(COMPONENTS main)
|
||||||
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/tools/unit-test-app/components")
|
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/tools/unit-test-app/components")
|
||||||
|
|
||||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
|
||||||
project(test_esp_event)
|
project(test_esp_event)
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
* SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
*
|
*
|
||||||
* SPDX-License-Identifier: Unlicense OR CC0-1.0
|
* SPDX-License-Identifier: Unlicense OR CC0-1.0
|
||||||
*/
|
*/
|
||||||
@@ -2014,7 +2014,7 @@ bool test_event_on_timer_alarm(gptimer_handle_t timer, const gptimer_alarm_event
|
|||||||
TEST_CASE("can post events from interrupt handler", "[event]")
|
TEST_CASE("can post events from interrupt handler", "[event]")
|
||||||
{
|
{
|
||||||
/* Lazy allocated resources in gptimer/intr_alloc */
|
/* Lazy allocated resources in gptimer/intr_alloc */
|
||||||
set_leak_threshold(-120);
|
set_leak_threshold(-150);
|
||||||
|
|
||||||
SemaphoreHandle_t sem = xSemaphoreCreateBinary();
|
SemaphoreHandle_t sem = xSemaphoreCreateBinary();
|
||||||
gptimer_handle_t gptimer = NULL;
|
gptimer_handle_t gptimer = NULL;
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
@@ -10,6 +10,4 @@ from pytest_embedded import Dut
|
|||||||
@pytest.mark.esp32c3
|
@pytest.mark.esp32c3
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
def test_esp_event(dut: Dut) -> None:
|
def test_esp_event(dut: Dut) -> None:
|
||||||
dut.expect('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=120)
|
|
||||||
|
@@ -2,6 +2,10 @@
|
|||||||
# CMakeLists in this exact order for cmake to work correctly
|
# CMakeLists in this exact order for cmake to work correctly
|
||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
|
||||||
|
set(SDKCONFIG_DEFAULTS "$ENV{IDF_PATH}/tools/test_apps/configs/sdkconfig.debug_helpers")
|
||||||
|
list(APPEND SDKCONFIG_DEFAULTS "sdkconfig.defaults")
|
||||||
|
|
||||||
|
# "Trim" the build. Include the minimal set of components, main, and anything it depends on.
|
||||||
set(COMPONENTS main)
|
set(COMPONENTS main)
|
||||||
|
|
||||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
@@ -17,6 +17,4 @@ from pytest_embedded import Dut
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
def test_esp_ringbuf(dut: Dut) -> None:
|
def test_esp_ringbuf(dut: Dut) -> None:
|
||||||
dut.expect('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output()
|
|
||||||
|
3
components/esp_ringbuf/test_apps/sdkconfig.defaults
Normal file
3
components/esp_ringbuf/test_apps/sdkconfig.defaults
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
# This "default" configuration is appended to all other configurations
|
||||||
|
# The contents of "sdkconfig.debug_helpers" is also appended to all other configurations (see CMakeLists.txt)
|
||||||
|
CONFIG_ESP_TASK_WDT_INIT=n
|
@@ -13,6 +13,4 @@ from pytest_embedded import Dut
|
|||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.nightly_run
|
@pytest.mark.nightly_run
|
||||||
def test_esp_rom(dut: Dut) -> None:
|
def test_esp_rom(dut: Dut) -> None:
|
||||||
dut.expect('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output()
|
|
||||||
|
@@ -70,7 +70,7 @@ TEST_CASE("reset reason ESP_RST_POWERON", "[reset][ignore]")
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#if !TEMPORARY_DISABLED_FOR_TARGETS(ESP32C2, ESP32C6)
|
#if !TEMPORARY_DISABLED_FOR_TARGETS(ESP32C2)
|
||||||
//IDF-5059
|
//IDF-5059
|
||||||
static __NOINIT_ATTR uint32_t s_noinit_val;
|
static __NOINIT_ATTR uint32_t s_noinit_val;
|
||||||
static RTC_NOINIT_ATTR uint32_t s_rtc_noinit_val;
|
static RTC_NOINIT_ATTR uint32_t s_rtc_noinit_val;
|
||||||
|
@@ -2,6 +2,6 @@
|
|||||||
|
|
||||||
components/esp_timer/test_apps:
|
components/esp_timer/test_apps:
|
||||||
disable:
|
disable:
|
||||||
- if: IDF_TARGET in ["esp32c6", "esp32h2"] # Sleep support IDF-6267
|
- if: IDF_TARGET in ["esp32h2"] # Sleep support IDF-6267
|
||||||
temporary: true
|
temporary: true
|
||||||
reason: Not supported yet
|
reason: Not supported yet
|
||||||
|
@@ -1,8 +1,12 @@
|
|||||||
#This is the project CMakeLists.txt file for the test subproject
|
#This is the project CMakeLists.txt file for the test subproject
|
||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
|
||||||
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/tools/unit-test-app/components")
|
set(SDKCONFIG_DEFAULTS "$ENV{IDF_PATH}/tools/test_apps/configs/sdkconfig.debug_helpers")
|
||||||
|
list(APPEND SDKCONFIG_DEFAULTS "sdkconfig.defaults")
|
||||||
|
|
||||||
|
# "Trim" the build. Include the minimal set of components, main, and anything it depends on.
|
||||||
set(COMPONENTS main)
|
set(COMPONENTS main)
|
||||||
|
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/tools/unit-test-app/components")
|
||||||
|
|
||||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||||
project(esp_timer_test)
|
project(esp_timer_test)
|
||||||
|
@@ -1,3 +1,3 @@
|
|||||||
| Supported Targets | ESP32 | ESP32-C2 | ESP32-C3 | ESP32-S2 | ESP32-S3 |
|
| Supported Targets | ESP32 | ESP32-C2 | ESP32-C3 | ESP32-C6 | ESP32-S2 | ESP32-S3 |
|
||||||
| ----------------- | ----- | -------- | -------- | -------- | -------- |
|
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- |
|
||||||
|
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
* SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
*
|
*
|
||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
@@ -13,6 +13,8 @@
|
|||||||
#include "esp_rom_sys.h"
|
#include "esp_rom_sys.h"
|
||||||
#include "esp_sleep.h"
|
#include "esp_sleep.h"
|
||||||
|
|
||||||
|
#if !TEMPORARY_DISABLED_FOR_TARGETS(ESP32C6) // TODO IDF-6770
|
||||||
|
|
||||||
static void timer_cb1(void *arg)
|
static void timer_cb1(void *arg)
|
||||||
{
|
{
|
||||||
++*((int*) arg);
|
++*((int*) arg);
|
||||||
@@ -50,3 +52,5 @@ TEST_CASE("Test the periodic timer does not handle lost events during light slee
|
|||||||
TEST_ESP_OK(esp_timer_dump(stdout));
|
TEST_ESP_OK(esp_timer_dump(stdout));
|
||||||
TEST_ESP_OK(esp_timer_delete(periodic_timer));
|
TEST_ESP_OK(esp_timer_delete(periodic_timer));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif //#!TEMPORARY_DISABLED_FOR_TARGETS(ESP32C6)
|
||||||
|
@@ -1,12 +1,12 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 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
|
||||||
|
|
||||||
CONFIGS = [
|
CONFIGS = [
|
||||||
pytest.param('general', marks=[pytest.mark.supported_targets, pytest.mark.temp_skip_ci(targets=['esp32c6'], reason='c6 support TBD')]),
|
pytest.param('general', marks=[pytest.mark.supported_targets]),
|
||||||
pytest.param('release', marks=[pytest.mark.supported_targets, pytest.mark.temp_skip_ci(targets=['esp32c6'], reason='c6 support TBD')]),
|
pytest.param('release', marks=[pytest.mark.supported_targets]),
|
||||||
pytest.param('single_core', marks=[pytest.mark.esp32]),
|
pytest.param('single_core', marks=[pytest.mark.esp32]),
|
||||||
pytest.param('freertos_compliance', marks=[pytest.mark.esp32]),
|
pytest.param('freertos_compliance', marks=[pytest.mark.esp32]),
|
||||||
pytest.param('isr_dispatch_esp32', marks=[pytest.mark.esp32]),
|
pytest.param('isr_dispatch_esp32', marks=[pytest.mark.esp32]),
|
||||||
@@ -16,9 +16,7 @@ CONFIGS = [
|
|||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.parametrize('config', CONFIGS, indirect=True)
|
@pytest.mark.parametrize('config', CONFIGS, indirect=True)
|
||||||
def test_esp_timer(dut: Dut) -> None:
|
def test_esp_timer(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases(timeout=120)
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=240)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.esp32
|
@pytest.mark.esp32
|
||||||
@@ -27,9 +25,7 @@ def test_esp_timer(dut: Dut) -> None:
|
|||||||
'psram',
|
'psram',
|
||||||
], indirect=True)
|
], indirect=True)
|
||||||
def test_esp_timer_psram(dut: Dut) -> None:
|
def test_esp_timer_psram(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases(timeout=120)
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=240)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.esp32c2
|
@pytest.mark.esp32c2
|
||||||
@@ -43,6 +39,4 @@ def test_esp_timer_psram(dut: Dut) -> None:
|
|||||||
indirect=True,
|
indirect=True,
|
||||||
)
|
)
|
||||||
def test_esp_timer_esp32c2_xtal_26mhz(dut: Dut) -> None:
|
def test_esp_timer_esp32c2_xtal_26mhz(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases(timeout=120)
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=240)
|
|
||||||
|
@@ -1,3 +1,4 @@
|
|||||||
|
CONFIG_IDF_TARGET="esp32"
|
||||||
CONFIG_SPIRAM=y
|
CONFIG_SPIRAM=y
|
||||||
CONFIG_ESP_INT_WDT_TIMEOUT_MS=800
|
CONFIG_ESP_INT_WDT_TIMEOUT_MS=800
|
||||||
CONFIG_SPIRAM_OCCUPY_NO_HOST=y
|
CONFIG_SPIRAM_OCCUPY_NO_HOST=y
|
||||||
|
@@ -1 +1,2 @@
|
|||||||
|
CONFIG_IDF_TARGET="esp32"
|
||||||
CONFIG_FREERTOS_UNICORE=y
|
CONFIG_FREERTOS_UNICORE=y
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
* SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
*
|
*
|
||||||
* SPDX-License-Identifier: Apache-2.0
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
*/
|
*/
|
||||||
@@ -15,7 +15,7 @@
|
|||||||
#include "unity.h"
|
#include "unity.h"
|
||||||
#include "test_utils.h"
|
#include "test_utils.h"
|
||||||
|
|
||||||
#if !TEMPORARY_DISABLED_FOR_TARGETS(ESP32C2, ESP32C3)
|
#if !TEMPORARY_DISABLED_FOR_TARGETS(ESP32C2, ESP32C3, ESP32C6)
|
||||||
typedef struct {
|
typedef struct {
|
||||||
StreamBufferHandle_t sb;
|
StreamBufferHandle_t sb;
|
||||||
SemaphoreHandle_t end_test;
|
SemaphoreHandle_t end_test;
|
||||||
|
@@ -5,22 +5,19 @@ import pytest
|
|||||||
from pytest_embedded import Dut
|
from pytest_embedded import Dut
|
||||||
|
|
||||||
CONFIGS = [
|
CONFIGS = [
|
||||||
pytest.param('default', marks=[pytest.mark.supported_targets, pytest.mark.temp_skip_ci(targets=['esp32c6'], reason='test failed')]),
|
pytest.param('default', marks=[pytest.mark.supported_targets]),
|
||||||
pytest.param('freertos_options', marks=[pytest.mark.supported_targets, pytest.mark.temp_skip_ci(targets=['esp32c6'], reason='test failed')]),
|
pytest.param('freertos_options', marks=[pytest.mark.supported_targets]),
|
||||||
pytest.param('psram', marks=[pytest.mark.esp32]),
|
pytest.param('psram', marks=[pytest.mark.esp32]),
|
||||||
pytest.param('release', marks=[pytest.mark.supported_targets]),
|
pytest.param('release', marks=[pytest.mark.supported_targets]),
|
||||||
pytest.param('single_core', marks=[pytest.mark.esp32]),
|
pytest.param('single_core', marks=[pytest.mark.esp32]),
|
||||||
pytest.param('smp', marks=[pytest.mark.supported_targets, pytest.mark.temp_skip_ci(targets=['esp32c6'], reason='test failed')]),
|
pytest.param('smp', marks=[pytest.mark.supported_targets]),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.parametrize('config', CONFIGS, indirect=True)
|
@pytest.mark.parametrize('config', CONFIGS, indirect=True)
|
||||||
def test_freertos(dut: Dut) -> None:
|
def test_freertos(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('![ignore]')
|
|
||||||
# All of the FreeRTOS tests combined take > 60s to run. So we use a 120s timeout
|
|
||||||
dut.expect_unity_test_output(timeout=120)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.supported_targets
|
||||||
|
@@ -44,7 +44,7 @@ TEST_CASE("Capabilities allocator test", "[heap]")
|
|||||||
TEST_ASSERT(free8<=(free8start-10*1024));
|
TEST_ASSERT(free8<=(free8start-10*1024));
|
||||||
TEST_ASSERT(free32<=(free32start-10*1024));
|
TEST_ASSERT(free32<=(free32start-10*1024));
|
||||||
//Assume we got DRAM back
|
//Assume we got DRAM back
|
||||||
TEST_ASSERT((((int)m1)&0xFF000000)==0x3F000000);
|
TEST_ASSERT(esp_ptr_in_dram(m1));
|
||||||
free(m1);
|
free(m1);
|
||||||
|
|
||||||
//The goal here is to allocate from IRAM. Since there is no external IRAM (yet)
|
//The goal here is to allocate from IRAM. Since there is no external IRAM (yet)
|
||||||
|
@@ -7,7 +7,6 @@ from pytest_embedded import Dut
|
|||||||
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.supported_targets
|
||||||
@pytest.mark.temp_skip_ci(targets=['esp32c6'], reason='test failed')
|
|
||||||
@pytest.mark.parametrize(
|
@pytest.mark.parametrize(
|
||||||
'config',
|
'config',
|
||||||
[
|
[
|
||||||
@@ -17,9 +16,7 @@ from pytest_embedded import Dut
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
def test_heap_poisoning(dut: Dut) -> None:
|
def test_heap_poisoning(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=300)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
@@ -34,9 +31,7 @@ def test_heap_poisoning(dut: Dut) -> None:
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
def test_heap(dut: Dut) -> None:
|
def test_heap(dut: Dut) -> None:
|
||||||
dut.expect_exact('Press ENTER to see the list of tests')
|
dut.run_all_single_board_cases()
|
||||||
dut.write('*')
|
|
||||||
dut.expect_unity_test_output(timeout=300)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
|
@@ -6,6 +6,8 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#define IDF_PERFORMANCE_MAX_ESP_TIMER_GET_TIME_PER_CALL 1200
|
||||||
|
|
||||||
// ECC peripheral output at 160MHz
|
// ECC peripheral output at 160MHz
|
||||||
#define IDF_PERFORMANCE_MAX_ECP_P192_POINT_MULTIPLY_OP 5000
|
#define IDF_PERFORMANCE_MAX_ECP_P192_POINT_MULTIPLY_OP 5000
|
||||||
#define IDF_PERFORMANCE_MAX_ECP_P192_POINT_VERIFY_OP 60
|
#define IDF_PERFORMANCE_MAX_ECP_P192_POINT_VERIFY_OP 60
|
||||||
|
@@ -1,7 +0,0 @@
|
|||||||
# Documentation: .gitlab/ci/README.md#manifest-file-to-control-the-buildtest-apps
|
|
||||||
|
|
||||||
components/newlib/test_apps:
|
|
||||||
disable:
|
|
||||||
- if: IDF_TARGET == "esp32c6"
|
|
||||||
temporary: true
|
|
||||||
reason: target esp32c6 is not supported yet
|
|
@@ -1,2 +1,2 @@
|
|||||||
| Supported Targets | ESP32 | ESP32-C2 | ESP32-C3 | ESP32-H2 | ESP32-S2 | ESP32-S3 |
|
| Supported Targets | ESP32 | ESP32-C2 | ESP32-C3 | ESP32-C6 | ESP32-H2 | ESP32-S2 | ESP32-S3 |
|
||||||
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- |
|
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- | -------- |
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
@@ -6,7 +6,6 @@ from pytest_embedded import Dut
|
|||||||
|
|
||||||
|
|
||||||
@pytest.mark.supported_targets
|
@pytest.mark.supported_targets
|
||||||
@pytest.mark.temp_skip_ci(targets=['esp32c6'], reason='c6 support TBD')
|
|
||||||
@pytest.mark.generic
|
@pytest.mark.generic
|
||||||
def test_newlib(dut: Dut) -> None:
|
def test_newlib(dut: Dut) -> None:
|
||||||
dut.expect_unity_test_output()
|
dut.expect_unity_test_output()
|
||||||
|
Reference in New Issue
Block a user