From eda7a7fe4c917c86629dbd8f3ec703a6cf62f2db Mon Sep 17 00:00:00 2001 From: Romulo Quidute Filho Date: Mon, 27 Jul 2026 11:30:47 -0300 Subject: [PATCH] Add nfc-ethernet to PairingMode and DutPairingModeEnum Mirrors the backend's app/constants/shared_constants.py so the CLI's enums stay in sync with the new NFC_ETHERNET pairing mode used for Matter-over-Ethernet commissioning over NFC in python_testing suites. Related: project-chip/certification-tool#1067 --- tests/test_config.py | 3 +++ th_cli/config.py | 1 + th_cli/shared_constants.py | 2 ++ 3 files changed, 6 insertions(+) diff --git a/tests/test_config.py b/tests/test_config.py index 9aa5518..5d987b9 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -274,6 +274,9 @@ def test_ble_thread_value(self): def test_nfc_thread_value(self): assert PairingMode.NFC_THREAD.value == "nfc-thread" + def test_nfc_ethernet_value(self): + assert PairingMode.NFC_ETHERNET.value == "nfc-ethernet" + def test_onnetwork_value(self): assert PairingMode.ONNETWORK.value == "onnetwork" diff --git a/th_cli/config.py b/th_cli/config.py index ff5ade6..1876f92 100644 --- a/th_cli/config.py +++ b/th_cli/config.py @@ -155,6 +155,7 @@ class PairingMode(str, Enum): BLE_THREAD = "ble-thread" WIFIPAF_WIFI = "wifipaf-wifi" NFC_THREAD = "nfc-thread" + NFC_ETHERNET = "nfc-ethernet" ONNETWORK = "onnetwork" diff --git a/th_cli/shared_constants.py b/th_cli/shared_constants.py index 788c02b..fabca2f 100644 --- a/th_cli/shared_constants.py +++ b/th_cli/shared_constants.py @@ -64,6 +64,7 @@ class DutPairingModeEnum(str, Enum): ON_NETWORK = "onnetwork" BLE_WIFI = "ble-wifi" NFC_WIFI = "nfc-wifi" + NFC_ETHERNET = "nfc-ethernet" BLE_THREAD = "ble-thread" WIFIPAF_WIFI = "wifipaf-wifi" NFC_THREAD = "nfc-thread" @@ -72,5 +73,6 @@ class DutPairingModeEnum(str, Enum): NFC_PAIRING_MODES = { DutPairingModeEnum.NFC_WIFI.value, + DutPairingModeEnum.NFC_ETHERNET.value, DutPairingModeEnum.NFC_THREAD.value, }