ci(adc): remove ADC runner and move ADC tests to generic

This commit is contained in:
gaoxu
2026-06-26 16:16:07 +08:00
parent 5a9313eb0f
commit e940896908
7 changed files with 18 additions and 23 deletions

View File

@@ -27,7 +27,7 @@
#elif CONFIG_IDF_TARGET_ESP32S2
#define ADC_TEST_LOW_VAL 0
#define ADC_TEST_LOW_THRESH 35
#define ADC_TEST_LOW_THRESH 40
#define ADC_TEST_HIGH_VAL 8191
#define ADC_TEST_HIGH_THRESH 10
@@ -48,7 +48,7 @@
#elif CONFIG_IDF_TARGET_ESP32C2
#define ADC_TEST_LOW_VAL 0
#define ADC_TEST_LOW_THRESH 15
#define ADC_TEST_LOW_THRESH 30
#define ADC_TEST_HIGH_VAL 3400
#define ADC_TEST_HIGH_THRESH 200

View File

@@ -1,6 +1,5 @@
# SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2021-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded import Dut
@@ -11,7 +10,7 @@ from pytest_embedded import Dut
@pytest.mark.esp32c3
@pytest.mark.esp32c6
@pytest.mark.esp32h2
@pytest.mark.adc
@pytest.mark.generic
@pytest.mark.parametrize(
'config',
[
@@ -24,7 +23,7 @@ def test_legacy_adc(dut: Dut) -> None:
@pytest.mark.esp32c2
@pytest.mark.adc
@pytest.mark.generic
@pytest.mark.xtal_26mhz
@pytest.mark.parametrize(
'config, baud',

View File

@@ -42,7 +42,7 @@ extern "C" {
#elif CONFIG_IDF_TARGET_ESP32S2
#define ADC_TEST_LOW_VAL 0
#define ADC_TEST_LOW_THRESH 35
#define ADC_TEST_LOW_THRESH 85
#define ADC_TEST_HIGH_VAL 8191
#define ADC_TEST_HIGH_VAL_DMA 4095
@@ -66,7 +66,7 @@ extern "C" {
#elif CONFIG_IDF_TARGET_ESP32C2
#define ADC_TEST_LOW_VAL 0
#define ADC_TEST_LOW_THRESH 15
#define ADC_TEST_LOW_THRESH 30
#define ADC_TEST_HIGH_VAL 3400
#define ADC_TEST_HIGH_THRESH 200

View File

@@ -1,6 +1,5 @@
# SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2021-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded import Dut
@@ -11,7 +10,7 @@ from pytest_embedded import Dut
@pytest.mark.esp32c3
@pytest.mark.esp32c6
@pytest.mark.esp32h2
@pytest.mark.adc
@pytest.mark.generic
@pytest.mark.parametrize('config', [
'iram_safe',
'release',
@@ -22,8 +21,8 @@ def test_adc(dut: Dut) -> None:
# No PM test, as C2 doesn't support ADC continuous mode
@pytest.mark.generic
@pytest.mark.esp32c2
@pytest.mark.adc
@pytest.mark.xtal_26mhz
@pytest.mark.parametrize(
'config, baud',
@@ -41,7 +40,7 @@ def test_adc_esp32c2_xtal_26mhz(dut: Dut) -> None:
@pytest.mark.esp32c3
@pytest.mark.esp32c6
@pytest.mark.esp32h2
@pytest.mark.adc
@pytest.mark.generic
@pytest.mark.parametrize('config', [
'gdma_iram_safe',
], indirect=True)

View File

@@ -1,6 +1,5 @@
# SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded.dut import Dut
@@ -11,7 +10,7 @@ from pytest_embedded.dut import Dut
@pytest.mark.esp32c3
@pytest.mark.esp32c6
@pytest.mark.esp32h2
@pytest.mark.adc
@pytest.mark.generic
def test_adc_continuous(dut: Dut) -> None:
res = dut.expect(r'TASK: ret is 0, ret_num is (\d+) bytes')
num = res.group(1).decode('utf8')

View File

@@ -1,6 +1,5 @@
# SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2021-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded.dut import Dut
@@ -11,13 +10,13 @@ from pytest_embedded.dut import Dut
@pytest.mark.esp32c3
@pytest.mark.esp32c6
@pytest.mark.esp32h2
@pytest.mark.adc
@pytest.mark.generic
def test_adc_oneshot(dut: Dut) -> None:
dut.expect(r'EXAMPLE: ADC1 Channel\[(\d+)\] Raw Data: (\d+)', timeout=5)
@pytest.mark.esp32c2
@pytest.mark.adc
@pytest.mark.generic
@pytest.mark.xtal_26mhz
@pytest.mark.parametrize(
'config, baud',

View File

@@ -1,12 +1,11 @@
# SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2021-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded import Dut
@pytest.mark.esp32
@pytest.mark.adc
@pytest.mark.generic
def test_dac_cosine_wave_example_with_12bit_adc(dut: Dut) -> None:
res = []
for _ in range(30):
@@ -20,7 +19,7 @@ def test_dac_cosine_wave_example_with_12bit_adc(dut: Dut) -> None:
@pytest.mark.esp32s2
@pytest.mark.adc
@pytest.mark.generic
def test_dac_cosine_wave_example_with_13bit_adc(dut: Dut) -> None:
res = []
for _ in range(30):