mirror of
https://github.com/espressif/esp-idf.git
synced 2025-11-18 10:31:09 +00:00
tools: merge C3 changes into master
This commit is contained in:
@@ -16,7 +16,8 @@ TEST_LABELS = {
|
||||
'test_apps': 'BOT_LABEL_CUSTOM_TEST',
|
||||
'component_ut': ['BOT_LABEL_UNIT_TEST',
|
||||
'BOT_LABEL_UNIT_TEST_32',
|
||||
'BOT_LABEL_UNIT_TEST_S2'],
|
||||
'BOT_LABEL_UNIT_TEST_S2',
|
||||
'BOT_LABEL_UNIT_TEST_C3'],
|
||||
}
|
||||
|
||||
BUILD_ALL_LABELS = [
|
||||
|
||||
@@ -80,17 +80,20 @@ class ExampleGroup(IDFCaseGroup):
|
||||
SORT_KEYS = CI_JOB_MATCH_KEYS = ['env_tag', 'target']
|
||||
|
||||
LOCAL_BUILD_DIR = 'build_examples'
|
||||
BUILD_JOB_NAMES = ['build_examples_cmake_{}'.format(target) for target in SUPPORTED_TARGETS]
|
||||
EXAMPLE_TARGETS = SUPPORTED_TARGETS + PREVIEW_TARGETS
|
||||
BUILD_JOB_NAMES = ['build_examples_cmake_{}'.format(target) for target in EXAMPLE_TARGETS]
|
||||
|
||||
|
||||
class TestAppsGroup(ExampleGroup):
|
||||
LOCAL_BUILD_DIR = 'build_test_apps'
|
||||
BUILD_JOB_NAMES = ['build_test_apps_{}'.format(target) for target in SUPPORTED_TARGETS]
|
||||
TEST_APP_TARGETS = SUPPORTED_TARGETS + PREVIEW_TARGETS
|
||||
BUILD_JOB_NAMES = ['build_test_apps_{}'.format(target) for target in TEST_APP_TARGETS]
|
||||
|
||||
|
||||
class ComponentUTGroup(TestAppsGroup):
|
||||
LOCAL_BUILD_DIR = 'build_component_ut'
|
||||
BUILD_JOB_NAMES = ['build_component_ut_{}'.format(target) for target in SUPPORTED_TARGETS]
|
||||
UNIT_TEST_TARGETS = SUPPORTED_TARGETS + PREVIEW_TARGETS
|
||||
BUILD_JOB_NAMES = ['build_component_ut_{}'.format(target) for target in UNIT_TEST_TARGETS]
|
||||
|
||||
|
||||
class UnitTestGroup(IDFCaseGroup):
|
||||
@@ -98,7 +101,8 @@ class UnitTestGroup(IDFCaseGroup):
|
||||
CI_JOB_MATCH_KEYS = ['test environment']
|
||||
|
||||
LOCAL_BUILD_DIR = 'tools/unit-test-app/builds'
|
||||
BUILD_JOB_NAMES = ['build_esp_idf_tests_cmake_{}'.format(target) for target in SUPPORTED_TARGETS]
|
||||
UNIT_TEST_TARGETS = SUPPORTED_TARGETS + PREVIEW_TARGETS
|
||||
BUILD_JOB_NAMES = ['build_esp_idf_tests_cmake_{}'.format(target) for target in UNIT_TEST_TARGETS]
|
||||
|
||||
MAX_CASE = 50
|
||||
ATTR_CONVERT_TABLE = {
|
||||
@@ -107,6 +111,7 @@ class UnitTestGroup(IDFCaseGroup):
|
||||
DUT_CLS_NAME = {
|
||||
'esp32': 'ESP32DUT',
|
||||
'esp32s2': 'ESP32S2DUT',
|
||||
'esp32c3': 'ESP32C3DUT',
|
||||
'esp8266': 'ESP8266DUT',
|
||||
}
|
||||
|
||||
|
||||
@@ -463,6 +463,9 @@ class ESP32DUT(IDFDUT):
|
||||
def _get_rom(cls):
|
||||
return esptool.ESP32ROM
|
||||
|
||||
def erase_partition(self, esp, partition):
|
||||
raise NotImplementedError()
|
||||
|
||||
|
||||
class ESP32S2DUT(IDFDUT):
|
||||
TARGET = "esp32s2"
|
||||
@@ -472,6 +475,21 @@ class ESP32S2DUT(IDFDUT):
|
||||
def _get_rom(cls):
|
||||
return esptool.ESP32S2ROM
|
||||
|
||||
def erase_partition(self, esp, partition):
|
||||
raise NotImplementedError()
|
||||
|
||||
|
||||
class ESP32C3DUT(IDFDUT):
|
||||
TARGET = "esp32c3"
|
||||
TOOLCHAIN_PREFIX = "riscv32-esp-elf-"
|
||||
|
||||
@classmethod
|
||||
def _get_rom(cls):
|
||||
return esptool.ESP32C3ROM
|
||||
|
||||
def erase_partition(self, esp, partition):
|
||||
raise NotImplementedError()
|
||||
|
||||
|
||||
class ESP8266DUT(IDFDUT):
|
||||
TARGET = "esp8266"
|
||||
@@ -481,9 +499,12 @@ class ESP8266DUT(IDFDUT):
|
||||
def _get_rom(cls):
|
||||
return esptool.ESP8266ROM
|
||||
|
||||
def erase_partition(self, esp, partition):
|
||||
raise NotImplementedError()
|
||||
|
||||
|
||||
def get_target_by_rom_class(cls):
|
||||
for c in [ESP32DUT, ESP32S2DUT, ESP8266DUT, IDFQEMUDUT]:
|
||||
for c in [ESP32DUT, ESP32S2DUT, ESP32C3DUT, ESP8266DUT, IDFQEMUDUT]:
|
||||
if c._get_rom() == cls:
|
||||
return c.TARGET
|
||||
return None
|
||||
|
||||
@@ -23,13 +23,14 @@ import junit_xml
|
||||
from tiny_test_fw import TinyFW, Utility
|
||||
from .DebugUtils import OCDBackend, GDBBackend, CustomProcess # noqa: export DebugUtils for users
|
||||
from .IDFApp import IDFApp, Example, LoadableElfTestApp, UT, TestApp, ComponentUTApp # noqa: export all Apps for users
|
||||
from .IDFDUT import IDFDUT, ESP32DUT, ESP32S2DUT, ESP8266DUT, ESP32QEMUDUT # noqa: export DUTs for users
|
||||
from .IDFDUT import IDFDUT, ESP32DUT, ESP32S2DUT, ESP32C3DUT, ESP8266DUT, ESP32QEMUDUT # noqa: export DUTs for users
|
||||
from .unity_test_parser import TestResults, TestFormat
|
||||
|
||||
# pass TARGET_DUT_CLS_DICT to Env.py to avoid circular dependency issue.
|
||||
TARGET_DUT_CLS_DICT = {
|
||||
'ESP32': ESP32DUT,
|
||||
'ESP32S2': ESP32S2DUT,
|
||||
'ESP32C3': ESP32C3DUT,
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user