2022-10-21 11:48:03 -04:00
|
|
|
# SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
|
|
|
# SPDX-License-Identifier: Unlicense OR CC0-1.0
|
|
|
|
|
2022-12-05 04:54:10 -05:00
|
|
|
from time import sleep
|
|
|
|
|
2022-10-21 11:48:03 -04:00
|
|
|
import pytest
|
|
|
|
from pytest_embedded import Dut
|
|
|
|
|
|
|
|
|
|
|
|
@pytest.mark.esp32
|
|
|
|
@pytest.mark.esp32c2
|
|
|
|
@pytest.mark.esp32c3
|
2022-11-22 04:01:25 -05:00
|
|
|
@pytest.mark.esp32c6
|
2022-10-21 11:48:03 -04:00
|
|
|
@pytest.mark.generic
|
|
|
|
def test_efuse(dut: Dut) -> None:
|
|
|
|
dut.expect_exact('Press ENTER to see the list of tests')
|
|
|
|
dut.write('*')
|
|
|
|
dut.expect_unity_test_output(timeout=200)
|
2022-12-05 04:54:10 -05:00
|
|
|
|
|
|
|
|
|
|
|
@pytest.mark.qemu
|
|
|
|
@pytest.mark.esp32
|
|
|
|
def test_efuse_qemu(dut: Dut) -> None:
|
|
|
|
dut.expect_exact('Press ENTER to see the list of tests')
|
|
|
|
# dut may not be ready to accept input, so adding the delay until handled in pytest embedded (RDT-328)
|
|
|
|
sleep(1)
|
|
|
|
dut.write('*')
|
|
|
|
dut.expect_unity_test_output(timeout=200)
|