test: format all test scripts

This commit is contained in:
Evgeny Torbin
2026-04-17 16:01:00 +02:00
committed by Fu Hanxi
parent 1740554ae3
commit 59f62ad15f
349 changed files with 4844 additions and 3464 deletions
@@ -1,12 +1,11 @@
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded import Dut
from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.esp32
@pytest.mark.esp32c3
@pytest.mark.generic
@idf_parametrize('target', ['esp32', 'esp32c3'], indirect=['target'])
def test_cxx_exception(dut: Dut) -> None:
dut.run_all_single_board_cases()
@@ -1,13 +1,12 @@
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded import Dut
from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.esp32
@pytest.mark.esp32c3
@pytest.mark.generic
@idf_parametrize('target', ['esp32', 'esp32c3'], indirect=['target'])
def test_cxx_noexcept_out_of_range(dut: Dut) -> None:
dut.expect_exact('Press ENTER to see the list of tests')
dut.write('1')
@@ -15,9 +14,8 @@ def test_cxx_noexcept_out_of_range(dut: Dut) -> None:
dut.expect_exact('Rebooting...')
@pytest.mark.esp32
@pytest.mark.esp32c3
@pytest.mark.generic
@idf_parametrize('target', ['esp32', 'esp32c3'], indirect=['target'])
def test_cxx_noexcept_bad_alloc(dut: Dut) -> None:
dut.expect_exact('Press ENTER to see the list of tests')
dut.write('2')
@@ -1,41 +1,35 @@
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded import Dut
from pytest_embedded_idf.utils import idf_parametrize
configurations = [
'noexcept',
'exceptions_rtti'
]
configurations = ['noexcept', 'exceptions_rtti']
@pytest.mark.esp32
@pytest.mark.esp32c3
@pytest.mark.generic
@pytest.mark.parametrize('config', configurations, indirect=True)
@idf_parametrize('target', ['esp32', 'esp32c3'], indirect=['target'])
def test_cxx_static_init_non_pod(dut: Dut) -> None:
dut.expect_exact('Press ENTER to see the list of tests')
dut.write('\"can use static initializers for non-POD types\"')
dut.write('"can use static initializers for non-POD types"')
dut.expect_unity_test_output()
@pytest.mark.esp32
@pytest.mark.esp32c3
@pytest.mark.generic
@pytest.mark.parametrize('config', configurations, indirect=True)
@idf_parametrize('target', ['esp32', 'esp32c3'], indirect=['target'])
def test_cxx_misc(dut: Dut) -> None:
dut.expect_exact('Press ENTER to see the list of tests')
dut.write('[misc]')
dut.expect_unity_test_output()
@pytest.mark.esp32
@pytest.mark.esp32c3
@pytest.mark.generic
@pytest.mark.parametrize('config', configurations, indirect=True)
@idf_parametrize('target', ['esp32', 'esp32c3'], indirect=['target'])
def test_cxx_stack_smash(dut: Dut) -> None:
dut.expect_exact('Press ENTER to see the list of tests')
dut.write('\"stack smashing protection CXX\"')
dut.write('"stack smashing protection CXX"')
dut.expect_exact('Stack smashing protect failure!')
dut.expect_exact('Rebooting...')
@@ -1,12 +1,11 @@
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
# SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
# SPDX-License-Identifier: CC0-1.0
import pytest
from pytest_embedded import Dut
from pytest_embedded_idf.utils import idf_parametrize
@pytest.mark.esp32
@pytest.mark.esp32c3
@pytest.mark.generic
@idf_parametrize('target', ['esp32', 'esp32c3'], indirect=['target'])
def test_cxx_rtti(dut: Dut) -> None:
dut.run_all_single_board_cases()