Revert "Refactoring of support test scripts to enhance matter testing infrast…" (#36016)
This reverts commit b1cd9fdc010748e6fa52dc5043f4b842952fe284.
diff --git a/docs/testing/python.md b/docs/testing/python.md
index 4541871..a957074 100644
--- a/docs/testing/python.md
+++ b/docs/testing/python.md
@@ -25,7 +25,7 @@
section should include various parameters and their respective values,
which will guide the test runner on how to execute the tests.
- All test classes inherit from `MatterBaseTest` in
- [matter_testing.py](https://github.com/project-chip/connectedhomeip/blob/master/src/python_testing/matter_testing_infrastructure/chip/testing/matter_testing.py)
+ [matter_testing_support.py](https://github.com/project-chip/connectedhomeip/blob/master/src/python_testing/matter_testing_support.py)
- Support for commissioning using the python controller
- Default controller (`self.default_controller`) of type `ChipDeviceCtrl`
- `MatterBaseTest` inherits from the Mobly BaseTestClass
@@ -38,7 +38,7 @@
decorated with the @async_test_body decorator
- Use `ChipDeviceCtrl` to interact with the DUT
- Controller API is in `ChipDeviceCtrl.py` (see API doc in file)
- - Some support methods in `matter_testing.py`
+ - Some support methods in `matter_testing_support.py`
- Use Mobly assertions for failing tests
- `self.step()` along with a `steps_*` method to mark test plan steps for cert
tests
@@ -379,7 +379,7 @@
## Mobly helpers
The test system is based on Mobly, and the
-[matter_testing.py](https://github.com/project-chip/connectedhomeip/blob/master/src/python_testing/matter_testing_infrastructure/chip/testing/matter_testing.py)
+[matter_testing_support.py](https://github.com/project-chip/connectedhomeip/blob/master/src/python_testing/matter_testing_support.py)
class provides some helpers for Mobly integration.
- `default_matter_test_main`
@@ -561,11 +561,11 @@
## Other support utilities
-- `basic_composition`
+- `basic_composition_support`
- wildcard read, whole device analysis
- `CommissioningFlowBlocks`
- various commissioning support for core tests
-- `spec_parsing`
+- `spec_parsing_support`
- parsing data model XML into python readable format
# Running tests locally
diff --git a/scripts/spec_xml/generate_spec_xml.py b/scripts/spec_xml/generate_spec_xml.py
index 43582fd..0d41b3f 100755
--- a/scripts/spec_xml/generate_spec_xml.py
+++ b/scripts/spec_xml/generate_spec_xml.py
@@ -24,17 +24,26 @@
from pathlib import Path
import click
-from paths import Branch, get_chip_root, get_data_model_path, get_documentation_file_path, get_in_progress_defines
-# Use the get_in_progress_defines() function to fetch the in-progress defines
-CURRENT_IN_PROGRESS_DEFINES = get_in_progress_defines()
+DEFAULT_CHIP_ROOT = os.path.abspath(
+ os.path.join(os.path.dirname(__file__), '..', '..'))
+DEFAULT_OUTPUT_DIR_1_3 = os.path.abspath(
+ os.path.join(DEFAULT_CHIP_ROOT, 'data_model', '1.3'))
+DEFAULT_OUTPUT_DIR_IN_PROGRESS = os.path.abspath(
+ os.path.join(DEFAULT_CHIP_ROOT, 'data_model', 'in_progress'))
+DEFAULT_OUTPUT_DIR_TOT = os.path.abspath(
+ os.path.join(DEFAULT_CHIP_ROOT, 'data_model', 'master'))
+DEFAULT_DOCUMENTATION_FILE = os.path.abspath(
+ os.path.join(DEFAULT_CHIP_ROOT, 'docs', 'spec_clusters.md'))
-# Replace hardcoded paths with dynamic paths using paths.py functions
-DEFAULT_CHIP_ROOT = get_chip_root()
-DEFAULT_OUTPUT_DIR_1_3 = get_data_model_path(Branch.V1_3)
-DEFAULT_OUTPUT_DIR_IN_PROGRESS = get_data_model_path(Branch.IN_PROGRESS)
-DEFAULT_OUTPUT_DIR_TOT = get_data_model_path(Branch.MASTER)
-DEFAULT_DOCUMENTATION_FILE = get_documentation_file_path()
+# questions
+# is energy-calendar still in?
+# is heat-pump out? wasn't in 0.7
+# location-cluster - is this define gone now?
+# queuedpreset - is this define gone now?
+CURRENT_IN_PROGRESS_DEFINES = ['aliro', 'atomicwrites', 'battery-storage', 'device-location', 'e2e-jf', 'energy-calendar', 'energy-drlc',
+ 'energy-management', 'heat-pump', 'hrap-1', 'hvac', 'matter-fabric-synchronization', 'metering', 'secondary-net',
+ 'service-area-cluster', 'solar-power', 'tcp', 'water-heater', 'wifiSetup']
def get_xml_path(filename, output_dir):
@@ -81,6 +90,7 @@
'--include-in-progress',
type=click.Choice(['All', 'None', 'Current']), default='All')
def main(scraper, spec_root, output_dir, dry_run, include_in_progress):
+ # Clusters need to be scraped first because the cluster directory is passed to the device type directory
if not output_dir:
output_dir_map = {'All': DEFAULT_OUTPUT_DIR_TOT, 'None': DEFAULT_OUTPUT_DIR_1_3, 'Current': DEFAULT_OUTPUT_DIR_IN_PROGRESS}
output_dir = output_dir_map[include_in_progress]
@@ -93,28 +103,30 @@
def scrape_clusters(scraper, spec_root, output_dir, dry_run, include_in_progress):
src_dir = os.path.abspath(os.path.join(spec_root, 'src'))
- sdm_clusters_dir = os.path.abspath(os.path.join(src_dir, 'service_device_management'))
+ sdm_clusters_dir = os.path.abspath(
+ os.path.join(src_dir, 'service_device_management'))
app_clusters_dir = os.path.abspath(os.path.join(src_dir, 'app_clusters'))
dm_clusters_dir = os.path.abspath(os.path.join(src_dir, 'data_model'))
- media_clusters_dir = os.path.abspath(os.path.join(app_clusters_dir, 'media'))
-
- clusters_output_dir = os.path.join(output_dir, 'clusters')
+ media_clusters_dir = os.path.abspath(
+ os.path.join(app_clusters_dir, 'media'))
+ clusters_output_dir = os.path.abspath(os.path.join(output_dir, 'clusters'))
if not os.path.exists(clusters_output_dir):
os.makedirs(clusters_output_dir)
- print('Generating main spec to get file include list - this may take a few minutes')
+ print('Generating main spec to get file include list - this make take a few minutes')
main_out = make_asciidoc('pdf', include_in_progress, spec_root, dry_run)
- print('Generating cluster spec to get file include list - this may take a few minutes')
+ print('Generating cluster spec to get file include list - this make take a few minutes')
cluster_out = make_asciidoc('pdf-appclusters-book', include_in_progress, spec_root, dry_run)
def scrape_cluster(filename: str) -> None:
base = Path(filename).stem
if base not in main_out and base not in cluster_out:
- print(f'Skipping file: {base} as it is not compiled into the asciidoc')
+ print(f'skipping file: {base} as it is not compiled into the asciidoc')
return
xml_path = get_xml_path(filename, clusters_output_dir)
- cmd = [scraper, 'cluster', '-i', filename, '-o', xml_path, '-nd']
+ cmd = [scraper, 'cluster', '-i', filename, '-o',
+ xml_path, '-nd']
if include_in_progress == 'All':
cmd.extend(['--define', 'in-progress'])
elif include_in_progress == 'Current':
@@ -138,29 +150,33 @@
tree = ElementTree.parse(f'{xml_path}')
root = tree.getroot()
cluster = next(root.iter('cluster'))
+ # If there's no cluster ID table, this isn't a cluster
try:
next(cluster.iter('clusterIds'))
except StopIteration:
+ # If there's no cluster ID table, this isn't a cluster just some kind of intro adoc
print(f'Removing file {xml_path} as it does not include any cluster definitions')
os.remove(xml_path)
continue
def scrape_device_types(scraper, spec_root, output_dir, dry_run, include_in_progress):
- device_type_dir = os.path.abspath(os.path.join(spec_root, 'src', 'device_types'))
- device_types_output_dir = os.path.abspath(os.path.join(output_dir, 'device_types'))
+ device_type_dir = os.path.abspath(
+ os.path.join(spec_root, 'src', 'device_types'))
+ device_types_output_dir = os.path.abspath(
+ os.path.join(output_dir, 'device_types'))
clusters_output_dir = os.path.abspath(os.path.join(output_dir, 'clusters'))
if not os.path.exists(device_types_output_dir):
os.makedirs(device_types_output_dir)
- print('Generating device type library to get file include list - this may take a few minutes')
+ print('Generating device type library to get file include list - this make take a few minutes')
device_type_output = make_asciidoc('pdf-devicelibrary-book', include_in_progress, spec_root, dry_run)
def scrape_device_type(filename: str) -> None:
base = Path(filename).stem
if base not in device_type_output:
- print(f'Skipping file: {filename} as it is not compiled into the asciidoc')
+ print(f'skipping file: {filename} as it is not compiled into the asciidoc')
return
xml_path = get_xml_path(filename, device_types_output_dir)
cmd = [scraper, 'devicetype', '-c', '-cls', clusters_output_dir,
diff --git a/scripts/spec_xml/paths.py b/scripts/spec_xml/paths.py
deleted file mode 100644
index 3a5159c..0000000
--- a/scripts/spec_xml/paths.py
+++ /dev/null
@@ -1,109 +0,0 @@
-#!/usr/bin/env python3
-
-# Copyright (c) 2024 Project CHIP Authors
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-import os
-from enum import Enum
-
-# Define a branch enum for different versions or branches
-
-
-class Branch(Enum):
- MASTER = "master"
- V1_3 = "v1_3"
- V1_4 = "v1_4"
- IN_PROGRESS = "in_progress"
-
-
-def get_chip_root():
- """
- Returns the CHIP root directory, trying the environment variable first
- and falling back if necessary.
- """
- chip_root = os.getenv('PW_PROJECT_ROOT')
- if chip_root:
- return chip_root
- else:
- try:
- return os.path.abspath(os.path.join(os.path.dirname(__file__), '..', '..'))
- except Exception as e:
- raise EnvironmentError(
- "Unable to determine CHIP root directory. Please ensure the environment is activated."
- ) from e
-
-
-def get_data_model_path(branch: Branch):
- """
- Returns the path to the data model directory for a given branch.
- """
- chip_root = get_chip_root()
- data_model_path = os.path.join(chip_root, 'data_model', branch.value)
- if not os.path.exists(data_model_path):
- raise FileNotFoundError(f"Data model path for branch {branch} does not exist: {data_model_path}")
- return data_model_path
-
-
-def get_spec_xml_output_path():
- """
- Returns the path to the output directory for generated XML files.
- """
- chip_root = get_chip_root()
- output_dir = os.path.join(chip_root, 'out', 'spec_xml')
- if not os.path.exists(output_dir):
- os.makedirs(output_dir) # Automatically create the directory if it doesn't exist
- return output_dir
-
-
-def get_documentation_file_path():
- """
- Returns the path to the documentation file.
- """
- chip_root = get_chip_root()
- documentation_file = os.path.join(chip_root, 'docs', 'spec_clusters.md')
- if not os.path.exists(documentation_file):
- raise FileNotFoundError(f"Documentation file does not exist: {documentation_file}")
- return documentation_file
-
-
-def get_python_testing_path():
- """
- Returns the path to the python_testing directory.
- """
- chip_root = get_chip_root()
- python_testing_path = os.path.join(chip_root, 'src', 'python_testing')
- if not os.path.exists(python_testing_path):
- raise FileNotFoundError(f"Python testing directory does not exist: {python_testing_path}")
- return python_testing_path
-
-
-def get_in_progress_defines():
- """
- Returns a list of defines that are currently in progress.
- This can be updated dynamically as needed.
- """
- return [
- 'aliro', 'atomicwrites', 'battery-storage', 'device-location', 'e2e-jf',
- 'energy-calendar', 'energy-drlc', 'energy-management', 'heat-pump', 'hrap-1',
- 'hvac', 'matter-fabric-synchronization', 'metering', 'secondary-net',
- 'service-area-cluster', 'solar-power', 'tcp', 'water-heater', 'wifiSetup'
- ]
-
-
-def get_available_branches():
- """
- Return a list of available branches for the data model.
- This can be expanded or dynamically fetched if necessary.
- """
- return [Branch.MASTER, Branch.V1_3, Branch.V1_4]
diff --git a/src/python_testing/MinimalRepresentation.py b/src/python_testing/MinimalRepresentation.py
index 93ce543..c99919a 100644
--- a/src/python_testing/MinimalRepresentation.py
+++ b/src/python_testing/MinimalRepresentation.py
@@ -17,10 +17,10 @@
from dataclasses import dataclass, field
-from chip.testing.conformance import ConformanceDecision
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
from chip.tlv import uint
+from conformance_support import ConformanceDecision
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from TC_DeviceConformance import DeviceConformanceTests
diff --git a/src/python_testing/TCP_Tests.py b/src/python_testing/TCP_Tests.py
index 1020934..849b3a9 100644
--- a/src/python_testing/TCP_Tests.py
+++ b/src/python_testing/TCP_Tests.py
@@ -33,7 +33,7 @@
import chip.clusters as Clusters
from chip import ChipDeviceCtrl
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_ACE_1_2.py b/src/python_testing/TC_ACE_1_2.py
index 5a38120..4955cbd 100644
--- a/src/python_testing/TC_ACE_1_2.py
+++ b/src/python_testing/TC_ACE_1_2.py
@@ -42,7 +42,7 @@
from chip.clusters.Attribute import EventReadResult, SubscriptionTransaction, TypedAttributePath
from chip.exceptions import ChipStackError
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_ACE_1_3.py b/src/python_testing/TC_ACE_1_3.py
index 2868d95..9e21088 100644
--- a/src/python_testing/TC_ACE_1_3.py
+++ b/src/python_testing/TC_ACE_1_3.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_ACE_1_4.py b/src/python_testing/TC_ACE_1_4.py
index 37577b6..0afdf03 100644
--- a/src/python_testing/TC_ACE_1_4.py
+++ b/src/python_testing/TC_ACE_1_4.py
@@ -42,7 +42,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
# This test requires several additional command line arguments
diff --git a/src/python_testing/TC_ACE_1_5.py b/src/python_testing/TC_ACE_1_5.py
index 15c7380..9766e9a 100644
--- a/src/python_testing/TC_ACE_1_5.py
+++ b/src/python_testing/TC_ACE_1_5.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip import ChipDeviceCtrl
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_ACL_2_11.py b/src/python_testing/TC_ACL_2_11.py
index e8aa253..9f4aea3 100644
--- a/src/python_testing/TC_ACL_2_11.py
+++ b/src/python_testing/TC_ACL_2_11.py
@@ -42,13 +42,13 @@
import queue
import chip.clusters as Clusters
+from basic_composition_support import arls_populated
from chip.clusters.Attribute import EventReadResult, SubscriptionTransaction, ValueDecodeFailure
from chip.clusters.ClusterObjects import ALL_ACCEPTED_COMMANDS, ALL_ATTRIBUTES, ALL_CLUSTERS, ClusterEvent
from chip.clusters.Objects import AccessControl
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.basic_composition import arls_populated
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_ACL_2_2.py b/src/python_testing/TC_ACL_2_2.py
index 6f5ed47..219be92 100644
--- a/src/python_testing/TC_ACL_2_2.py
+++ b/src/python_testing/TC_ACL_2_2.py
@@ -32,7 +32,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_AccessChecker.py b/src/python_testing/TC_AccessChecker.py
index 5f3b3d6..23e8535 100644
--- a/src/python_testing/TC_AccessChecker.py
+++ b/src/python_testing/TC_AccessChecker.py
@@ -23,13 +23,13 @@
from typing import Optional
import chip.clusters as Clusters
+from basic_composition_support import BasicCompositionTests
from chip.interaction_model import Status
-from chip.testing.basic_composition import BasicCompositionTests
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import (AttributePathLocation, ClusterPathLocation, MatterBaseTest, TestStep, async_test_body,
- default_matter_test_main)
-from chip.testing.spec_parsing import XmlCluster, build_xml_clusters
from chip.tlv import uint
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import (AttributePathLocation, ClusterPathLocation, MatterBaseTest, TestStep, async_test_body,
+ default_matter_test_main)
+from spec_parsing_support import XmlCluster, build_xml_clusters
class AccessTestType(Enum):
diff --git a/src/python_testing/TC_BOOLCFG_2_1.py b/src/python_testing/TC_BOOLCFG_2_1.py
index 2e90245..27e016d 100644
--- a/src/python_testing/TC_BOOLCFG_2_1.py
+++ b/src/python_testing/TC_BOOLCFG_2_1.py
@@ -36,7 +36,7 @@
from operator import ior
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_BOOLCFG_3_1.py b/src/python_testing/TC_BOOLCFG_3_1.py
index 8ed77f6..4b3156b 100644
--- a/src/python_testing/TC_BOOLCFG_3_1.py
+++ b/src/python_testing/TC_BOOLCFG_3_1.py
@@ -36,7 +36,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_BOOLCFG_4_1.py b/src/python_testing/TC_BOOLCFG_4_1.py
index dfe6aac..3cd7f3a 100644
--- a/src/python_testing/TC_BOOLCFG_4_1.py
+++ b/src/python_testing/TC_BOOLCFG_4_1.py
@@ -34,7 +34,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_BOOLCFG_4_2.py b/src/python_testing/TC_BOOLCFG_4_2.py
index 093e389..7897847 100644
--- a/src/python_testing/TC_BOOLCFG_4_2.py
+++ b/src/python_testing/TC_BOOLCFG_4_2.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
sensorTrigger = 0x0080_0000_0000_0000
diff --git a/src/python_testing/TC_BOOLCFG_4_3.py b/src/python_testing/TC_BOOLCFG_4_3.py
index 845d8e9..aeb245a 100644
--- a/src/python_testing/TC_BOOLCFG_4_3.py
+++ b/src/python_testing/TC_BOOLCFG_4_3.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
sensorTrigger = 0x0080_0000_0000_0000
diff --git a/src/python_testing/TC_BOOLCFG_4_4.py b/src/python_testing/TC_BOOLCFG_4_4.py
index c585b14..66a1d06 100644
--- a/src/python_testing/TC_BOOLCFG_4_4.py
+++ b/src/python_testing/TC_BOOLCFG_4_4.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
sensorTrigger = 0x0080_0000_0000_0000
diff --git a/src/python_testing/TC_BOOLCFG_5_1.py b/src/python_testing/TC_BOOLCFG_5_1.py
index ec31d83..cef0eae 100644
--- a/src/python_testing/TC_BOOLCFG_5_1.py
+++ b/src/python_testing/TC_BOOLCFG_5_1.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
sensorTrigger = 0x0080_0000_0000_0000
diff --git a/src/python_testing/TC_BOOLCFG_5_2.py b/src/python_testing/TC_BOOLCFG_5_2.py
index fd6b883..6ab8c82 100644
--- a/src/python_testing/TC_BOOLCFG_5_2.py
+++ b/src/python_testing/TC_BOOLCFG_5_2.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
sensorTrigger = 0x0080_0000_0000_0000
diff --git a/src/python_testing/TC_BRBINFO_4_1.py b/src/python_testing/TC_BRBINFO_4_1.py
index f5eeec3..07b6fc2 100644
--- a/src/python_testing/TC_BRBINFO_4_1.py
+++ b/src/python_testing/TC_BRBINFO_4_1.py
@@ -53,7 +53,7 @@
from chip import ChipDeviceCtrl
from chip.interaction_model import InteractionModelError, Status
from chip.testing.apps import IcdAppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, SimpleEventCallback, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, SimpleEventCallback, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_CADMIN_1_9.py b/src/python_testing/TC_CADMIN_1_9.py
index b3b09af..060a540 100644
--- a/src/python_testing/TC_CADMIN_1_9.py
+++ b/src/python_testing/TC_CADMIN_1_9.py
@@ -40,7 +40,7 @@
from chip.ChipDeviceCtrl import CommissioningParameters
from chip.exceptions import ChipStackError
from chip.native import PyChipError
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_CCTRL_2_1.py b/src/python_testing/TC_CCTRL_2_1.py
index b656973..c689dd6 100644
--- a/src/python_testing/TC_CCTRL_2_1.py
+++ b/src/python_testing/TC_CCTRL_2_1.py
@@ -38,7 +38,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, default_matter_test_main, has_cluster, run_if_endpoint_matches
+from matter_testing_support import MatterBaseTest, TestStep, default_matter_test_main, has_cluster, run_if_endpoint_matches
from mobly import asserts
diff --git a/src/python_testing/TC_CCTRL_2_2.py b/src/python_testing/TC_CCTRL_2_2.py
index a2e7b15..76e8e83 100644
--- a/src/python_testing/TC_CCTRL_2_2.py
+++ b/src/python_testing/TC_CCTRL_2_2.py
@@ -50,8 +50,8 @@
from chip import ChipDeviceCtrl
from chip.interaction_model import InteractionModelError, Status
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import (MatterBaseTest, TestStep, async_test_body, default_matter_test_main, has_cluster,
- run_if_endpoint_matches)
+from matter_testing_support import (MatterBaseTest, TestStep, async_test_body, default_matter_test_main, has_cluster,
+ run_if_endpoint_matches)
from mobly import asserts
diff --git a/src/python_testing/TC_CCTRL_2_3.py b/src/python_testing/TC_CCTRL_2_3.py
index fe7ed3d..07d5706 100644
--- a/src/python_testing/TC_CCTRL_2_3.py
+++ b/src/python_testing/TC_CCTRL_2_3.py
@@ -50,8 +50,8 @@
from chip import ChipDeviceCtrl
from chip.interaction_model import InteractionModelError, Status
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import (MatterBaseTest, TestStep, async_test_body, default_matter_test_main, has_cluster,
- run_if_endpoint_matches)
+from matter_testing_support import (MatterBaseTest, TestStep, async_test_body, default_matter_test_main, has_cluster,
+ run_if_endpoint_matches)
from mobly import asserts
diff --git a/src/python_testing/TC_CC_10_1.py b/src/python_testing/TC_CC_10_1.py
index c2c76ec..2cbbf0f 100644
--- a/src/python_testing/TC_CC_10_1.py
+++ b/src/python_testing/TC_CC_10_1.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
kCCAttributeValueIDs = [0x0001, 0x0003, 0x0004, 0x0007, 0x4000, 0x4001, 0x4002, 0x4003, 0x4004]
diff --git a/src/python_testing/TC_CC_2_2.py b/src/python_testing/TC_CC_2_2.py
index f974364..647bee1 100644
--- a/src/python_testing/TC_CC_2_2.py
+++ b/src/python_testing/TC_CC_2_2.py
@@ -41,8 +41,8 @@
import chip.clusters as Clusters
from chip.clusters import ClusterObjects as ClusterObjects
-from chip.testing.matter_testing import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, default_matter_test_main,
- has_cluster, run_if_endpoint_matches)
+from matter_testing_support import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, default_matter_test_main,
+ has_cluster, run_if_endpoint_matches)
from mobly import asserts
from test_plan_support import commission_if_required, read_attribute, verify_success
@@ -88,8 +88,7 @@
14, f'{THcommand} MoveHue with _MoveMode_ field set to Down, _Rate_ field set to 255 and remaining fields set to 0', verify_success()),
TestStep(
15, f'{THcommand} MoveSaturation with _MoveMode_ field set to Down, _Rate_ field set to 255 and remaining fields set to 0', verify_success()),
- TestStep(16, f'{
- THcommand} MoveToHue with _Hue_ field set to 254, _TransitionTime_ field set to 100, _Direction_ field set to Shortest and remaining fields set to 0', verify_success()),
+ TestStep(16, f'{THcommand} MoveToHue with _Hue_ field set to 254, _TransitionTime_ field set to 100, _Direction_ field set to Shortest and remaining fields set to 0', verify_success()),
TestStep(17, store_values('reportedCurrentHueValuesList', 'CurrentHue')),
TestStep(18, verify_entry_count('reportedCurrentHueValuesList', 'CurrentHue'),
entry_count_verification('reportedCurrentHueValuesList')),
diff --git a/src/python_testing/TC_CGEN_2_4.py b/src/python_testing/TC_CGEN_2_4.py
index 7db0ddc..1cf2f7e 100644
--- a/src/python_testing/TC_CGEN_2_4.py
+++ b/src/python_testing/TC_CGEN_2_4.py
@@ -46,7 +46,7 @@
from chip.ChipDeviceCtrl import CommissioningParameters
from chip.exceptions import ChipStackError
from chip.native import PyChipError
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
# Commissioning stage numbers - we should find a better way to match these to the C++ code
diff --git a/src/python_testing/TC_CNET_1_4.py b/src/python_testing/TC_CNET_1_4.py
index 2c69456..7e19f8d 100644
--- a/src/python_testing/TC_CNET_1_4.py
+++ b/src/python_testing/TC_CNET_1_4.py
@@ -38,7 +38,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
kRootEndpointId = 0
diff --git a/src/python_testing/TC_CNET_4_4.py b/src/python_testing/TC_CNET_4_4.py
index 223cfdf..12407e6 100644
--- a/src/python_testing/TC_CNET_4_4.py
+++ b/src/python_testing/TC_CNET_4_4.py
@@ -22,7 +22,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_DA_1_2.py b/src/python_testing/TC_DA_1_2.py
index 9bf08fe..9fa60cd 100644
--- a/src/python_testing/TC_DA_1_2.py
+++ b/src/python_testing/TC_DA_1_2.py
@@ -40,10 +40,8 @@
import re
import chip.clusters as Clusters
+from basic_composition_support import BasicCompositionTests
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.basic_composition import BasicCompositionTests
-from chip.testing.matter_testing import (MatterBaseTest, TestStep, async_test_body, default_matter_test_main, hex_from_bytes,
- type_matches)
from chip.tlv import TLVReader
from cryptography import x509
from cryptography.exceptions import InvalidSignature
@@ -51,6 +49,7 @@
from cryptography.hazmat.primitives import hashes
from cryptography.hazmat.primitives.asymmetric import ec, utils
from ecdsa.curves import curve_by_name
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, hex_from_bytes, type_matches
from mobly import asserts
from pyasn1.codec.der.decoder import decode as der_decoder
from pyasn1.error import PyAsn1Error
diff --git a/src/python_testing/TC_DA_1_5.py b/src/python_testing/TC_DA_1_5.py
index e8e6ce7..c08f4eb 100644
--- a/src/python_testing/TC_DA_1_5.py
+++ b/src/python_testing/TC_DA_1_5.py
@@ -40,12 +40,12 @@
import chip.clusters as Clusters
from chip import ChipDeviceCtrl
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, hex_from_bytes, type_matches
from chip.tlv import TLVReader
from cryptography import x509
from cryptography.hazmat.primitives import hashes
from cryptography.hazmat.primitives.asymmetric import ec, utils
from ecdsa.curves import curve_by_name
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, hex_from_bytes, type_matches
from mobly import asserts
from pyasn1.codec.der.decoder import decode as der_decoder
from pyasn1.error import PyAsn1Error
diff --git a/src/python_testing/TC_DA_1_7.py b/src/python_testing/TC_DA_1_7.py
index 6678080..1130a7b 100644
--- a/src/python_testing/TC_DA_1_7.py
+++ b/src/python_testing/TC_DA_1_7.py
@@ -41,13 +41,13 @@
from typing import List, Optional
import chip.clusters as Clusters
-from chip.testing.matter_testing import (MatterBaseTest, TestStep, async_test_body, bytes_from_hex, default_matter_test_main,
- hex_from_bytes)
from cryptography.exceptions import InvalidSignature
from cryptography.hazmat.primitives import hashes
from cryptography.hazmat.primitives.asymmetric import ec
from cryptography.hazmat.primitives.serialization import Encoding, PublicFormat
from cryptography.x509 import AuthorityKeyIdentifier, Certificate, SubjectKeyIdentifier, load_der_x509_certificate
+from matter_testing_support import (MatterBaseTest, TestStep, async_test_body, bytes_from_hex, default_matter_test_main,
+ hex_from_bytes)
from mobly import asserts
# Those are SDK samples that are known to be non-production.
diff --git a/src/python_testing/TC_DEMTestBase.py b/src/python_testing/TC_DEMTestBase.py
index 49c8c6a..da51ba2 100644
--- a/src/python_testing/TC_DEMTestBase.py
+++ b/src/python_testing/TC_DEMTestBase.py
@@ -19,7 +19,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import utc_time_in_matter_epoch
+from matter_testing_support import utc_time_in_matter_epoch
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_DEM_2_1.py b/src/python_testing/TC_DEM_2_1.py
index 851099c..4975d3a 100644
--- a/src/python_testing/TC_DEM_2_1.py
+++ b/src/python_testing/TC_DEM_2_1.py
@@ -49,7 +49,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_10.py b/src/python_testing/TC_DEM_2_10.py
index 810efdb..8f2e0ba 100644
--- a/src/python_testing/TC_DEM_2_10.py
+++ b/src/python_testing/TC_DEM_2_10.py
@@ -50,8 +50,8 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, async_test_body,
- default_matter_test_main)
+from matter_testing_support import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, async_test_body,
+ default_matter_test_main)
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_2.py b/src/python_testing/TC_DEM_2_2.py
index 168417d..b5e26e4 100644
--- a/src/python_testing/TC_DEM_2_2.py
+++ b/src/python_testing/TC_DEM_2_2.py
@@ -52,7 +52,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_3.py b/src/python_testing/TC_DEM_2_3.py
index c5699c0..25398b4 100644
--- a/src/python_testing/TC_DEM_2_3.py
+++ b/src/python_testing/TC_DEM_2_3.py
@@ -46,7 +46,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_4.py b/src/python_testing/TC_DEM_2_4.py
index 1b591cd..6a396fc 100644
--- a/src/python_testing/TC_DEM_2_4.py
+++ b/src/python_testing/TC_DEM_2_4.py
@@ -47,7 +47,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import Status
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_5.py b/src/python_testing/TC_DEM_2_5.py
index c845ec1..f7f7d75 100644
--- a/src/python_testing/TC_DEM_2_5.py
+++ b/src/python_testing/TC_DEM_2_5.py
@@ -49,7 +49,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_6.py b/src/python_testing/TC_DEM_2_6.py
index 32dea4a..2e2a96f 100644
--- a/src/python_testing/TC_DEM_2_6.py
+++ b/src/python_testing/TC_DEM_2_6.py
@@ -49,7 +49,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_7.py b/src/python_testing/TC_DEM_2_7.py
index 44c65fb..36e7ab9 100644
--- a/src/python_testing/TC_DEM_2_7.py
+++ b/src/python_testing/TC_DEM_2_7.py
@@ -49,7 +49,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_8.py b/src/python_testing/TC_DEM_2_8.py
index 016778f..1f3d240 100644
--- a/src/python_testing/TC_DEM_2_8.py
+++ b/src/python_testing/TC_DEM_2_8.py
@@ -49,7 +49,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DEM_2_9.py b/src/python_testing/TC_DEM_2_9.py
index 05111e3..4541b9c 100644
--- a/src/python_testing/TC_DEM_2_9.py
+++ b/src/python_testing/TC_DEM_2_9.py
@@ -48,7 +48,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_DEMTestBase import DEMTestBase
diff --git a/src/python_testing/TC_DGGEN_2_4.py b/src/python_testing/TC_DGGEN_2_4.py
index 17b0684..27542e6 100644
--- a/src/python_testing/TC_DGGEN_2_4.py
+++ b/src/python_testing/TC_DGGEN_2_4.py
@@ -40,9 +40,8 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, async_test_body, default_matter_test_main,
- matter_epoch_us_from_utc_datetime, utc_datetime_from_matter_epoch_us,
- utc_datetime_from_posix_time_ms)
+from matter_testing_support import (MatterBaseTest, async_test_body, default_matter_test_main, matter_epoch_us_from_utc_datetime,
+ utc_datetime_from_matter_epoch_us, utc_datetime_from_posix_time_ms)
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_DGGEN_3_2.py b/src/python_testing/TC_DGGEN_3_2.py
index 58c333e..7e5af6c 100644
--- a/src/python_testing/TC_DGGEN_3_2.py
+++ b/src/python_testing/TC_DGGEN_3_2.py
@@ -16,7 +16,7 @@
#
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_DGSW_2_1.py b/src/python_testing/TC_DGSW_2_1.py
index 6338932..46ed696 100644
--- a/src/python_testing/TC_DGSW_2_1.py
+++ b/src/python_testing/TC_DGSW_2_1.py
@@ -36,7 +36,7 @@
#
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_DRLK_2_12.py b/src/python_testing/TC_DRLK_2_12.py
index 342fbc6..cf63bd8 100644
--- a/src/python_testing/TC_DRLK_2_12.py
+++ b/src/python_testing/TC_DRLK_2_12.py
@@ -35,8 +35,8 @@
# quiet: true
# === END CI TEST ARGUMENTS ===
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
from drlk_2_x_common import DRLK_COMMON
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
# Configurable parameters:
# - userIndex: userIndex to use when creating a user on the DUT for testing purposes
diff --git a/src/python_testing/TC_DRLK_2_13.py b/src/python_testing/TC_DRLK_2_13.py
index 809e278..dc1b69d 100644
--- a/src/python_testing/TC_DRLK_2_13.py
+++ b/src/python_testing/TC_DRLK_2_13.py
@@ -43,7 +43,7 @@
from chip.clusters.Attribute import EventPriority
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_DRLK_2_2.py b/src/python_testing/TC_DRLK_2_2.py
index f9f192f..84a511b 100644
--- a/src/python_testing/TC_DRLK_2_2.py
+++ b/src/python_testing/TC_DRLK_2_2.py
@@ -35,8 +35,8 @@
# quiet: true
# === END CI TEST ARGUMENTS ===
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
from drlk_2_x_common import DRLK_COMMON
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
# Configurable parameters:
# - userIndex: userIndex to use when creating a user on the DUT for testing purposes
diff --git a/src/python_testing/TC_DRLK_2_3.py b/src/python_testing/TC_DRLK_2_3.py
index 114f41a..7569086 100644
--- a/src/python_testing/TC_DRLK_2_3.py
+++ b/src/python_testing/TC_DRLK_2_3.py
@@ -35,8 +35,8 @@
# quiet: true
# === END CI TEST ARGUMENTS ===
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
from drlk_2_x_common import DRLK_COMMON
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
# Configurable parameters:
# - userIndex: userIndex to use when creating a user on the DUT for testing purposes
diff --git a/src/python_testing/TC_DRLK_2_5.py b/src/python_testing/TC_DRLK_2_5.py
index 84451d2..defe78e 100644
--- a/src/python_testing/TC_DRLK_2_5.py
+++ b/src/python_testing/TC_DRLK_2_5.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_DRLK_2_9.py b/src/python_testing/TC_DRLK_2_9.py
index fb294b7..b92eaf4 100644
--- a/src/python_testing/TC_DRLK_2_9.py
+++ b/src/python_testing/TC_DRLK_2_9.py
@@ -41,8 +41,8 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from drlk_2_x_common import DRLK_COMMON
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_DeviceBasicComposition.py b/src/python_testing/TC_DeviceBasicComposition.py
index e0e9d86..9ff05d4 100644
--- a/src/python_testing/TC_DeviceBasicComposition.py
+++ b/src/python_testing/TC_DeviceBasicComposition.py
@@ -103,19 +103,19 @@
import chip.clusters as Clusters
import chip.clusters.ClusterObjects
import chip.tlv
+from basic_composition_support import BasicCompositionTests
from chip import ChipUtility
from chip.clusters.Attribute import ValueDecodeFailure
from chip.clusters.ClusterObjects import ClusterAttributeDescriptor, ClusterObjectFieldDescriptor
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.basic_composition import BasicCompositionTests
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, MatterBaseTest, TestStep,
- async_test_body, default_matter_test_main)
-from chip.testing.taglist_and_topology_test import (create_device_type_list_for_root, create_device_type_lists,
- find_tag_list_problems, find_tree_roots, flat_list_ok,
- get_direct_children_of_root, parts_list_cycles, separate_endpoint_types)
from chip.tlv import uint
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, MatterBaseTest, TestStep,
+ async_test_body, default_matter_test_main)
from mobly import asserts
+from taglist_and_topology_test_support import (create_device_type_list_for_root, create_device_type_lists, find_tag_list_problems,
+ find_tree_roots, flat_list_ok, get_direct_children_of_root, parts_list_cycles,
+ separate_endpoint_types)
def check_int_in_range(min_value: int, max_value: int, allow_null: bool = False) -> Callable:
@@ -511,14 +511,12 @@
attribute_id=manufacturer_value)
if suffix > attribute_standard_range_max and suffix < global_range_min:
self.record_error(self.get_test_name(), location=location,
- problem=f"Manufacturer attribute in undefined range {
- manufacturer_value} in cluster {cluster_id}",
+ problem=f"Manufacturer attribute in undefined range {manufacturer_value} in cluster {cluster_id}",
spec_location=f"Cluster {cluster_id}")
success = False
elif suffix >= global_range_min:
self.record_error(self.get_test_name(), location=location,
- problem=f"Manufacturer attribute in global range {
- manufacturer_value} in cluster {cluster_id}",
+ problem=f"Manufacturer attribute in global range {manufacturer_value} in cluster {cluster_id}",
spec_location=f"Cluster {cluster_id}")
success = False
@@ -815,8 +813,7 @@
for ep, problem in problems.items():
location = AttributePathLocation(endpoint_id=ep, cluster_id=Clusters.Descriptor.id,
attribute_id=Clusters.Descriptor.Attributes.TagList.attribute_id)
- msg = f'problem on ep {ep}: missing feature = {problem.missing_feature}, missing attribute = {
- problem.missing_attribute}, duplicates = {problem.duplicates}, same_tags = {problem.same_tag}'
+ msg = f'problem on ep {ep}: missing feature = {problem.missing_feature}, missing attribute = {problem.missing_attribute}, duplicates = {problem.duplicates}, same_tags = {problem.same_tag}'
self.record_error(self.get_test_name(), location=location, problem=msg, spec_location="Descriptor TagList")
self.print_step(2, "Identify all the direct children of the root node endpoint")
diff --git a/src/python_testing/TC_DeviceConformance.py b/src/python_testing/TC_DeviceConformance.py
index a3e350b..8e700b4 100644
--- a/src/python_testing/TC_DeviceConformance.py
+++ b/src/python_testing/TC_DeviceConformance.py
@@ -39,16 +39,16 @@
from typing import Callable
import chip.clusters as Clusters
-from chip.testing.basic_composition import BasicCompositionTests
-from chip.testing.choice_conformance import (evaluate_attribute_choice_conformance, evaluate_command_choice_conformance,
- evaluate_feature_choice_conformance)
-from chip.testing.conformance import ConformanceDecision, conformance_allowed
-from chip.testing.global_attribute_ids import (ClusterIdType, DeviceTypeIdType, GlobalAttributeIds, cluster_id_type,
- device_type_id_type, is_valid_device_type_id)
-from chip.testing.matter_testing import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, DeviceTypePathLocation,
- MatterBaseTest, ProblemNotice, ProblemSeverity, async_test_body, default_matter_test_main)
-from chip.testing.spec_parsing import CommandType, build_xml_clusters, build_xml_device_types
+from basic_composition_support import BasicCompositionTests
from chip.tlv import uint
+from choice_conformance_support import (evaluate_attribute_choice_conformance, evaluate_command_choice_conformance,
+ evaluate_feature_choice_conformance)
+from conformance_support import ConformanceDecision, conformance_allowed
+from global_attribute_ids import (ClusterIdType, DeviceTypeIdType, GlobalAttributeIds, cluster_id_type, device_type_id_type,
+ is_valid_device_type_id)
+from matter_testing_support import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, DeviceTypePathLocation,
+ MatterBaseTest, ProblemNotice, ProblemSeverity, async_test_body, default_matter_test_main)
+from spec_parsing_support import CommandType, build_xml_clusters, build_xml_device_types
class DeviceConformanceTests(BasicCompositionTests):
diff --git a/src/python_testing/TC_ECOINFO_2_1.py b/src/python_testing/TC_ECOINFO_2_1.py
index a0adf75..1cb6ec2 100644
--- a/src/python_testing/TC_ECOINFO_2_1.py
+++ b/src/python_testing/TC_ECOINFO_2_1.py
@@ -47,8 +47,8 @@
from chip.clusters.Types import NullValue
from chip.interaction_model import Status
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from chip.tlv import uint
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_ECOINFO_2_2.py b/src/python_testing/TC_ECOINFO_2_2.py
index 403544b..85868a9 100644
--- a/src/python_testing/TC_ECOINFO_2_2.py
+++ b/src/python_testing/TC_ECOINFO_2_2.py
@@ -46,7 +46,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
_DEVICE_TYPE_AGGREGGATOR = 0x000E
diff --git a/src/python_testing/TC_EEM_2_1.py b/src/python_testing/TC_EEM_2_1.py
index 653bd94..0b6b480 100644
--- a/src/python_testing/TC_EEM_2_1.py
+++ b/src/python_testing/TC_EEM_2_1.py
@@ -43,7 +43,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EnergyReporting_Utils import EnergyReportingBaseTestHelper
diff --git a/src/python_testing/TC_EEM_2_2.py b/src/python_testing/TC_EEM_2_2.py
index 408cd85..6058aa3 100644
--- a/src/python_testing/TC_EEM_2_2.py
+++ b/src/python_testing/TC_EEM_2_2.py
@@ -41,7 +41,7 @@
import time
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EnergyReporting_Utils import EnergyReportingBaseTestHelper
diff --git a/src/python_testing/TC_EEM_2_3.py b/src/python_testing/TC_EEM_2_3.py
index 69a41b0..6e8bd7d 100644
--- a/src/python_testing/TC_EEM_2_3.py
+++ b/src/python_testing/TC_EEM_2_3.py
@@ -41,7 +41,7 @@
import time
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EnergyReporting_Utils import EnergyReportingBaseTestHelper
diff --git a/src/python_testing/TC_EEM_2_4.py b/src/python_testing/TC_EEM_2_4.py
index 0f67fb0..fb5d5f6 100644
--- a/src/python_testing/TC_EEM_2_4.py
+++ b/src/python_testing/TC_EEM_2_4.py
@@ -41,7 +41,7 @@
import time
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EnergyReporting_Utils import EnergyReportingBaseTestHelper
diff --git a/src/python_testing/TC_EEM_2_5.py b/src/python_testing/TC_EEM_2_5.py
index 43cb2cd..1408e2b 100644
--- a/src/python_testing/TC_EEM_2_5.py
+++ b/src/python_testing/TC_EEM_2_5.py
@@ -41,7 +41,7 @@
import time
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EnergyReporting_Utils import EnergyReportingBaseTestHelper
diff --git a/src/python_testing/TC_EEVSE_2_2.py b/src/python_testing/TC_EEVSE_2_2.py
index 144bfd8..61e52ed 100644
--- a/src/python_testing/TC_EEVSE_2_2.py
+++ b/src/python_testing/TC_EEVSE_2_2.py
@@ -46,7 +46,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EEVSE_Utils import EEVSEBaseTestHelper
diff --git a/src/python_testing/TC_EEVSE_2_3.py b/src/python_testing/TC_EEVSE_2_3.py
index 6494f4a..92005f3 100644
--- a/src/python_testing/TC_EEVSE_2_3.py
+++ b/src/python_testing/TC_EEVSE_2_3.py
@@ -46,7 +46,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import Status
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EEVSE_Utils import EEVSEBaseTestHelper
@@ -191,7 +191,7 @@
logger.info(
f"minutesPastMidnight = {minutes_past_midnight} => "
- f"{int(minutes_past_midnight/60)}:{int(minutes_past_midnight % 60)}"
+ f"{int(minutes_past_midnight/60)}:{int(minutes_past_midnight%60)}"
f" Expected target_time = {target_time}")
target_time_delta = target_time - \
diff --git a/src/python_testing/TC_EEVSE_2_4.py b/src/python_testing/TC_EEVSE_2_4.py
index 10355de..aaebf64 100644
--- a/src/python_testing/TC_EEVSE_2_4.py
+++ b/src/python_testing/TC_EEVSE_2_4.py
@@ -45,7 +45,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_EEVSE_Utils import EEVSEBaseTestHelper
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_EEVSE_2_5.py b/src/python_testing/TC_EEVSE_2_5.py
index 4571cfb..b25cfe1 100644
--- a/src/python_testing/TC_EEVSE_2_5.py
+++ b/src/python_testing/TC_EEVSE_2_5.py
@@ -45,7 +45,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import Status
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_EEVSE_Utils import EEVSEBaseTestHelper
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_EEVSE_2_6.py b/src/python_testing/TC_EEVSE_2_6.py
index d66ff60..8f809b4 100644
--- a/src/python_testing/TC_EEVSE_2_6.py
+++ b/src/python_testing/TC_EEVSE_2_6.py
@@ -45,8 +45,8 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import (ClusterAttributeChangeAccumulator, EventChangeCallback, MatterBaseTest, TestStep,
- async_test_body, default_matter_test_main)
+from matter_testing_support import (ClusterAttributeChangeAccumulator, EventChangeCallback, MatterBaseTest, TestStep,
+ async_test_body, default_matter_test_main)
from mobly import asserts
from TC_EEVSE_Utils import EEVSEBaseTestHelper
diff --git a/src/python_testing/TC_EPM_2_1.py b/src/python_testing/TC_EPM_2_1.py
index 0f3c74e..f12cafe 100644
--- a/src/python_testing/TC_EPM_2_1.py
+++ b/src/python_testing/TC_EPM_2_1.py
@@ -42,7 +42,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EnergyReporting_Utils import EnergyReportingBaseTestHelper
@@ -148,8 +148,7 @@
"minMeasuredValue must be the same as 1st accuracyRange rangeMin")
for index, range_entry in enumerate(measurement.accuracyRanges):
- logging.info(f" [{index}] rangeMin: {range_entry.rangeMin} rangeMax: {range_entry.rangeMax} percentMax: {range_entry.percentMax} percentMin: {
- range_entry.percentMin} percentTypical: {range_entry.percentTypical} fixedMax: {range_entry.fixedMax} fixedMin: {range_entry.fixedMin} fixedTypical: {range_entry.fixedTypical}")
+ logging.info(f" [{index}] rangeMin:{range_entry.rangeMin} rangeMax:{range_entry.rangeMax} percentMax:{range_entry.percentMax} percentMin:{range_entry.percentMin} percentTypical:{range_entry.percentTypical} fixedMax:{range_entry.fixedMax} fixedMin:{range_entry.fixedMin} fixedTypical:{range_entry.fixedTypical}")
asserts.assert_greater(
range_entry.rangeMax, range_entry.rangeMin, "rangeMax should be > rangeMin")
if index == 0:
diff --git a/src/python_testing/TC_EPM_2_2.py b/src/python_testing/TC_EPM_2_2.py
index d817042..97e9e04 100644
--- a/src/python_testing/TC_EPM_2_2.py
+++ b/src/python_testing/TC_EPM_2_2.py
@@ -42,7 +42,7 @@
import logging
import time
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EnergyReporting_Utils import EnergyReportingBaseTestHelper
diff --git a/src/python_testing/TC_EWATERHTR_2_1.py b/src/python_testing/TC_EWATERHTR_2_1.py
index 82c9e93..ced3b16 100644
--- a/src/python_testing/TC_EWATERHTR_2_1.py
+++ b/src/python_testing/TC_EWATERHTR_2_1.py
@@ -45,7 +45,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EWATERHTRBase import EWATERHTRBase
diff --git a/src/python_testing/TC_EWATERHTR_2_2.py b/src/python_testing/TC_EWATERHTR_2_2.py
index 1bd7185..11e8d54 100644
--- a/src/python_testing/TC_EWATERHTR_2_2.py
+++ b/src/python_testing/TC_EWATERHTR_2_2.py
@@ -47,7 +47,7 @@
import time
import chip.clusters as Clusters
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EWATERHTRBase import EWATERHTRBase
diff --git a/src/python_testing/TC_EWATERHTR_2_3.py b/src/python_testing/TC_EWATERHTR_2_3.py
index 0f1c3de..5f7df8c 100644
--- a/src/python_testing/TC_EWATERHTR_2_3.py
+++ b/src/python_testing/TC_EWATERHTR_2_3.py
@@ -45,7 +45,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import EventChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from TC_EWATERHTRBase import EWATERHTRBase
diff --git a/src/python_testing/TC_FAN_3_1.py b/src/python_testing/TC_FAN_3_1.py
index 483be89..f832250 100644
--- a/src/python_testing/TC_FAN_3_1.py
+++ b/src/python_testing/TC_FAN_3_1.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_FAN_3_2.py b/src/python_testing/TC_FAN_3_2.py
index 799510e..736c970 100644
--- a/src/python_testing/TC_FAN_3_2.py
+++ b/src/python_testing/TC_FAN_3_2.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_FAN_3_3.py b/src/python_testing/TC_FAN_3_3.py
index 7a4dde3..935811d 100644
--- a/src/python_testing/TC_FAN_3_3.py
+++ b/src/python_testing/TC_FAN_3_3.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_FAN_3_4.py b/src/python_testing/TC_FAN_3_4.py
index 989680e..7223393 100644
--- a/src/python_testing/TC_FAN_3_4.py
+++ b/src/python_testing/TC_FAN_3_4.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
# import time
diff --git a/src/python_testing/TC_FAN_3_5.py b/src/python_testing/TC_FAN_3_5.py
index 26dfc3e..d03f99e 100644
--- a/src/python_testing/TC_FAN_3_5.py
+++ b/src/python_testing/TC_FAN_3_5.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_ICDM_2_1.py b/src/python_testing/TC_ICDM_2_1.py
index 8d7f6d5..35d1cb6 100644
--- a/src/python_testing/TC_ICDM_2_1.py
+++ b/src/python_testing/TC_ICDM_2_1.py
@@ -39,7 +39,7 @@
import re
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_ICDM_3_1.py b/src/python_testing/TC_ICDM_3_1.py
index 58181a6..d46d725 100644
--- a/src/python_testing/TC_ICDM_3_1.py
+++ b/src/python_testing/TC_ICDM_3_1.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_ICDM_3_2.py b/src/python_testing/TC_ICDM_3_2.py
index d9800d6..924c6f4 100644
--- a/src/python_testing/TC_ICDM_3_2.py
+++ b/src/python_testing/TC_ICDM_3_2.py
@@ -42,7 +42,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_ICDM_3_3.py b/src/python_testing/TC_ICDM_3_3.py
index d261e53..bc1d698 100644
--- a/src/python_testing/TC_ICDM_3_3.py
+++ b/src/python_testing/TC_ICDM_3_3.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_ICDM_3_4.py b/src/python_testing/TC_ICDM_3_4.py
index 8ff2a57..4ebb325 100644
--- a/src/python_testing/TC_ICDM_3_4.py
+++ b/src/python_testing/TC_ICDM_3_4.py
@@ -40,8 +40,8 @@
import time
import chip.clusters as Clusters
-from chip.testing.matter_testing import (MatterBaseTest, MatterStackState, MatterTestConfig, TestStep, async_test_body,
- default_matter_test_main)
+from matter_testing_support import (MatterBaseTest, MatterStackState, MatterTestConfig, TestStep, async_test_body,
+ default_matter_test_main)
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_ICDM_5_1.py b/src/python_testing/TC_ICDM_5_1.py
index dacfe58..4b7222b 100644
--- a/src/python_testing/TC_ICDM_5_1.py
+++ b/src/python_testing/TC_ICDM_5_1.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mdns_discovery import mdns_discovery
from mobly import asserts
diff --git a/src/python_testing/TC_ICDManagementCluster.py b/src/python_testing/TC_ICDManagementCluster.py
index c0437cb..07c889a 100644
--- a/src/python_testing/TC_ICDManagementCluster.py
+++ b/src/python_testing/TC_ICDManagementCluster.py
@@ -42,7 +42,7 @@
from enum import IntEnum
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
# Assumes `--enable-key 000102030405060708090a0b0c0d0e0f` on Linux app command line, or a DUT
diff --git a/src/python_testing/TC_IDM_1_2.py b/src/python_testing/TC_IDM_1_2.py
index a1db9ba..7bfb97c 100644
--- a/src/python_testing/TC_IDM_1_2.py
+++ b/src/python_testing/TC_IDM_1_2.py
@@ -44,7 +44,7 @@
from chip import ChipUtility
from chip.exceptions import ChipStackError
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_IDM_1_4.py b/src/python_testing/TC_IDM_1_4.py
index 7419413..b00de41 100644
--- a/src/python_testing/TC_IDM_1_4.py
+++ b/src/python_testing/TC_IDM_1_4.py
@@ -44,7 +44,7 @@
import chip.clusters as Clusters
from chip.exceptions import ChipStackError
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
# If DUT supports `MaxPathsPerInvoke > 1`, additional command line argument
diff --git a/src/python_testing/TC_IDM_4_2.py b/src/python_testing/TC_IDM_4_2.py
index 0f4cd51..d9e876b 100644
--- a/src/python_testing/TC_IDM_4_2.py
+++ b/src/python_testing/TC_IDM_4_2.py
@@ -44,7 +44,7 @@
from chip.clusters.Attribute import AttributePath, TypedAttributePath
from chip.exceptions import ChipStackError
from chip.interaction_model import Status
-from chip.testing.matter_testing import AttributeChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import AttributeChangeCallback, MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
'''
diff --git a/src/python_testing/TC_LVL_2_3.py b/src/python_testing/TC_LVL_2_3.py
index d120bb7..94c33d5 100644
--- a/src/python_testing/TC_LVL_2_3.py
+++ b/src/python_testing/TC_LVL_2_3.py
@@ -41,8 +41,8 @@
import chip.clusters as Clusters
import test_plan_support
-from chip.testing.matter_testing import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, default_matter_test_main,
- has_cluster, run_if_endpoint_matches)
+from matter_testing_support import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, default_matter_test_main,
+ has_cluster, run_if_endpoint_matches)
from mobly import asserts
diff --git a/src/python_testing/TC_MCORE_FS_1_1.py b/src/python_testing/TC_MCORE_FS_1_1.py
index 995a80c..a04cbf0 100755
--- a/src/python_testing/TC_MCORE_FS_1_1.py
+++ b/src/python_testing/TC_MCORE_FS_1_1.py
@@ -48,7 +48,7 @@
import chip.clusters as Clusters
from chip import ChipDeviceCtrl
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
_DEVICE_TYPE_AGGREGATOR = 0x000E
diff --git a/src/python_testing/TC_MCORE_FS_1_2.py b/src/python_testing/TC_MCORE_FS_1_2.py
index f806db4..a7d318c 100644
--- a/src/python_testing/TC_MCORE_FS_1_2.py
+++ b/src/python_testing/TC_MCORE_FS_1_2.py
@@ -51,8 +51,8 @@
import chip.clusters as Clusters
from chip import ChipDeviceCtrl
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from ecdsa.curves import NIST256p
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
from TC_SC_3_6 import AttributeChangeAccumulator
diff --git a/src/python_testing/TC_MCORE_FS_1_3.py b/src/python_testing/TC_MCORE_FS_1_3.py
index 2ac1556..c0b3e83 100644
--- a/src/python_testing/TC_MCORE_FS_1_3.py
+++ b/src/python_testing/TC_MCORE_FS_1_3.py
@@ -51,7 +51,7 @@
from chip import ChipDeviceCtrl
from chip.interaction_model import Status
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
_DEVICE_TYPE_AGGREGATOR = 0x000E
diff --git a/src/python_testing/TC_MCORE_FS_1_4.py b/src/python_testing/TC_MCORE_FS_1_4.py
index 795e81c..74a8bec 100644
--- a/src/python_testing/TC_MCORE_FS_1_4.py
+++ b/src/python_testing/TC_MCORE_FS_1_4.py
@@ -50,8 +50,8 @@
from chip import ChipDeviceCtrl
from chip.interaction_model import Status
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from chip.testing.tasks import Subprocess
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_MCORE_FS_1_5.py b/src/python_testing/TC_MCORE_FS_1_5.py
index 59549fd..57ae214 100755
--- a/src/python_testing/TC_MCORE_FS_1_5.py
+++ b/src/python_testing/TC_MCORE_FS_1_5.py
@@ -51,8 +51,8 @@
import chip.clusters as Clusters
from chip import ChipDeviceCtrl
from chip.testing.apps import AppServerSubprocess
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from ecdsa.curves import NIST256p
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
from TC_SC_3_6 import AttributeChangeAccumulator
diff --git a/src/python_testing/TC_MWOCTRL_2_1.py b/src/python_testing/TC_MWOCTRL_2_1.py
index 6f91357..57c51fa 100644
--- a/src/python_testing/TC_MWOCTRL_2_1.py
+++ b/src/python_testing/TC_MWOCTRL_2_1.py
@@ -37,7 +37,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
# This test requires several additional command line arguments
diff --git a/src/python_testing/TC_MWOCTRL_2_2.py b/src/python_testing/TC_MWOCTRL_2_2.py
index 4559689..35eef08 100644
--- a/src/python_testing/TC_MWOCTRL_2_2.py
+++ b/src/python_testing/TC_MWOCTRL_2_2.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
# This test requires several additional command line arguments
diff --git a/src/python_testing/TC_MWOCTRL_2_4.py b/src/python_testing/TC_MWOCTRL_2_4.py
index e05c4a5..9e11724 100644
--- a/src/python_testing/TC_MWOCTRL_2_4.py
+++ b/src/python_testing/TC_MWOCTRL_2_4.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
# This test requires several additional command line arguments
diff --git a/src/python_testing/TC_MWOM_1_2.py b/src/python_testing/TC_MWOM_1_2.py
index 5cad6ce..8a77623 100644
--- a/src/python_testing/TC_MWOM_1_2.py
+++ b/src/python_testing/TC_MWOM_1_2.py
@@ -37,7 +37,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_OCC_2_1.py b/src/python_testing/TC_OCC_2_1.py
index d831d48..885ec6b 100644
--- a/src/python_testing/TC_OCC_2_1.py
+++ b/src/python_testing/TC_OCC_2_1.py
@@ -43,7 +43,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_OCC_2_2.py b/src/python_testing/TC_OCC_2_2.py
index bf5e97e..463b813 100644
--- a/src/python_testing/TC_OCC_2_2.py
+++ b/src/python_testing/TC_OCC_2_2.py
@@ -37,7 +37,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
@@ -133,8 +133,7 @@
asserts.assert_equal(
(occupancy_sensor_type_bitmap_dut & sensor_bit) != 0,
(feature_map & feature_bit) != 0,
- f"Feature bit and sensor bitmap must be equal for {
- name}(BITMAP: 0x{occupancy_sensor_type_bitmap_dut: 02X}, FEATUREMAP: 0x{feature_map: 02X})"
+ f"Feature bit and sensor bitmap must be equal for {name} (BITMAP: 0x{occupancy_sensor_type_bitmap_dut:02X}, FEATUREMAP: 0x{feature_map:02X})"
)
diff --git a/src/python_testing/TC_OCC_2_3.py b/src/python_testing/TC_OCC_2_3.py
index 8d4b53f..9c6cb80 100644
--- a/src/python_testing/TC_OCC_2_3.py
+++ b/src/python_testing/TC_OCC_2_3.py
@@ -39,7 +39,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_OCC_3_1.py b/src/python_testing/TC_OCC_3_1.py
index cce0a2f..b6ba0ea 100644
--- a/src/python_testing/TC_OCC_3_1.py
+++ b/src/python_testing/TC_OCC_3_1.py
@@ -43,8 +43,8 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import (ClusterAttributeChangeAccumulator, EventChangeCallback, MatterBaseTest, TestStep,
- async_test_body, await_sequence_of_reports, default_matter_test_main)
+from matter_testing_support import (ClusterAttributeChangeAccumulator, EventChangeCallback, MatterBaseTest, TestStep,
+ async_test_body, await_sequence_of_reports, default_matter_test_main)
from mobly import asserts
diff --git a/src/python_testing/TC_OCC_3_2.py b/src/python_testing/TC_OCC_3_2.py
index 3a5ca17..d4e5f18 100644
--- a/src/python_testing/TC_OCC_3_2.py
+++ b/src/python_testing/TC_OCC_3_2.py
@@ -44,8 +44,8 @@
import time
import chip.clusters as Clusters
-from chip.testing.matter_testing import (AttributeValue, ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep,
- async_test_body, await_sequence_of_reports, default_matter_test_main)
+from matter_testing_support import (AttributeValue, ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, async_test_body,
+ await_sequence_of_reports, default_matter_test_main)
from mobly import asserts
diff --git a/src/python_testing/TC_OPCREDS_3_1.py b/src/python_testing/TC_OPCREDS_3_1.py
index 1506d2a..be21c6d 100644
--- a/src/python_testing/TC_OPCREDS_3_1.py
+++ b/src/python_testing/TC_OPCREDS_3_1.py
@@ -42,8 +42,8 @@
from chip import ChipDeviceCtrl
from chip.exceptions import ChipStackError
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
from chip.tlv import TLVReader, TLVWriter
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_OPCREDS_3_2.py b/src/python_testing/TC_OPCREDS_3_2.py
index 2bfc214..91e2958 100644
--- a/src/python_testing/TC_OPCREDS_3_2.py
+++ b/src/python_testing/TC_OPCREDS_3_2.py
@@ -36,9 +36,9 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from chip.tlv import TLVReader
from chip.utils import CommissioningBuildingBlocks
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
from test_plan_support import (commission_from_existing, commission_if_required, read_attribute, remove_fabric,
verify_commissioning_successful, verify_success)
diff --git a/src/python_testing/TC_OPSTATE_2_1.py b/src/python_testing/TC_OPSTATE_2_1.py
index 060b71d..1b6966a 100644
--- a/src/python_testing/TC_OPSTATE_2_1.py
+++ b/src/python_testing/TC_OPSTATE_2_1.py
@@ -37,7 +37,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OPSTATE_2_2.py b/src/python_testing/TC_OPSTATE_2_2.py
index f0ed8f2..8617d3d 100644
--- a/src/python_testing/TC_OPSTATE_2_2.py
+++ b/src/python_testing/TC_OPSTATE_2_2.py
@@ -38,7 +38,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OPSTATE_2_3.py b/src/python_testing/TC_OPSTATE_2_3.py
index d35aa6e..3671747 100644
--- a/src/python_testing/TC_OPSTATE_2_3.py
+++ b/src/python_testing/TC_OPSTATE_2_3.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OPSTATE_2_4.py b/src/python_testing/TC_OPSTATE_2_4.py
index ec2c7c1..d468227 100644
--- a/src/python_testing/TC_OPSTATE_2_4.py
+++ b/src/python_testing/TC_OPSTATE_2_4.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OPSTATE_2_5.py b/src/python_testing/TC_OPSTATE_2_5.py
index 89a2462..687f4d2 100644
--- a/src/python_testing/TC_OPSTATE_2_5.py
+++ b/src/python_testing/TC_OPSTATE_2_5.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OPSTATE_2_6.py b/src/python_testing/TC_OPSTATE_2_6.py
index 0b9e1ec..9441569 100644
--- a/src/python_testing/TC_OPSTATE_2_6.py
+++ b/src/python_testing/TC_OPSTATE_2_6.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OVENOPSTATE_2_1.py b/src/python_testing/TC_OVENOPSTATE_2_1.py
index d830a41..6bf7226 100644
--- a/src/python_testing/TC_OVENOPSTATE_2_1.py
+++ b/src/python_testing/TC_OVENOPSTATE_2_1.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OVENOPSTATE_2_2.py b/src/python_testing/TC_OVENOPSTATE_2_2.py
index 55afad1..2fa1215 100644
--- a/src/python_testing/TC_OVENOPSTATE_2_2.py
+++ b/src/python_testing/TC_OVENOPSTATE_2_2.py
@@ -38,7 +38,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OVENOPSTATE_2_3.py b/src/python_testing/TC_OVENOPSTATE_2_3.py
index 329bceb..815fcef 100644
--- a/src/python_testing/TC_OVENOPSTATE_2_3.py
+++ b/src/python_testing/TC_OVENOPSTATE_2_3.py
@@ -38,7 +38,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OVENOPSTATE_2_4.py b/src/python_testing/TC_OVENOPSTATE_2_4.py
index ffc6393..892bf28 100644
--- a/src/python_testing/TC_OVENOPSTATE_2_4.py
+++ b/src/python_testing/TC_OVENOPSTATE_2_4.py
@@ -38,7 +38,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OVENOPSTATE_2_5.py b/src/python_testing/TC_OVENOPSTATE_2_5.py
index 42edca7..4fd9ef9 100644
--- a/src/python_testing/TC_OVENOPSTATE_2_5.py
+++ b/src/python_testing/TC_OVENOPSTATE_2_5.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OVENOPSTATE_2_6.py b/src/python_testing/TC_OVENOPSTATE_2_6.py
index 2770625..db4b390 100644
--- a/src/python_testing/TC_OVENOPSTATE_2_6.py
+++ b/src/python_testing/TC_OVENOPSTATE_2_6.py
@@ -39,7 +39,7 @@
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from TC_OpstateCommon import TC_OPSTATE_BASE, TestInfo
diff --git a/src/python_testing/TC_OpstateCommon.py b/src/python_testing/TC_OpstateCommon.py
index 557b760..c697c7a 100644
--- a/src/python_testing/TC_OpstateCommon.py
+++ b/src/python_testing/TC_OpstateCommon.py
@@ -27,7 +27,7 @@
from chip.clusters.Attribute import EventReadResult, SubscriptionTransaction
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import ClusterAttributeChangeAccumulator, EventChangeCallback, TestStep
+from matter_testing_support import ClusterAttributeChangeAccumulator, EventChangeCallback, TestStep
from mobly import asserts
diff --git a/src/python_testing/TC_PS_2_3.py b/src/python_testing/TC_PS_2_3.py
index 13f4420..dbff20e 100644
--- a/src/python_testing/TC_PS_2_3.py
+++ b/src/python_testing/TC_PS_2_3.py
@@ -38,8 +38,8 @@
import time
import chip.clusters as Clusters
-from chip.testing.matter_testing import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, async_test_body,
- default_matter_test_main)
+from matter_testing_support import (ClusterAttributeChangeAccumulator, MatterBaseTest, TestStep, async_test_body,
+ default_matter_test_main)
from mobly import asserts
diff --git a/src/python_testing/TC_PWRTL_2_1.py b/src/python_testing/TC_PWRTL_2_1.py
index 3de09c6..639bd3d 100644
--- a/src/python_testing/TC_PWRTL_2_1.py
+++ b/src/python_testing/TC_PWRTL_2_1.py
@@ -37,7 +37,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_RR_1_1.py b/src/python_testing/TC_RR_1_1.py
index 0cbf027..2785171 100644
--- a/src/python_testing/TC_RR_1_1.py
+++ b/src/python_testing/TC_RR_1_1.py
@@ -45,8 +45,8 @@
import chip.clusters as Clusters
from chip.interaction_model import Status as StatusEnum
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
from chip.utils import CommissioningBuildingBlocks
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
from TC_SC_3_6 import AttributeChangeAccumulator, ResubscriptionCatcher
diff --git a/src/python_testing/TC_RVCCLEANM_1_2.py b/src/python_testing/TC_RVCCLEANM_1_2.py
index 3dfd75f..9e4bca4 100644
--- a/src/python_testing/TC_RVCCLEANM_1_2.py
+++ b/src/python_testing/TC_RVCCLEANM_1_2.py
@@ -39,7 +39,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_RVCCLEANM_2_1.py b/src/python_testing/TC_RVCCLEANM_2_1.py
index 5234a74..2c4ddd1 100644
--- a/src/python_testing/TC_RVCCLEANM_2_1.py
+++ b/src/python_testing/TC_RVCCLEANM_2_1.py
@@ -41,7 +41,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
# This test requires several additional command line arguments
diff --git a/src/python_testing/TC_RVCCLEANM_2_2.py b/src/python_testing/TC_RVCCLEANM_2_2.py
index 7352d03..5262465 100644
--- a/src/python_testing/TC_RVCCLEANM_2_2.py
+++ b/src/python_testing/TC_RVCCLEANM_2_2.py
@@ -39,7 +39,7 @@
import enum
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_RVCOPSTATE_2_1.py b/src/python_testing/TC_RVCOPSTATE_2_1.py
index 48715c3..ae3e6c3 100644
--- a/src/python_testing/TC_RVCOPSTATE_2_1.py
+++ b/src/python_testing/TC_RVCOPSTATE_2_1.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_RVCOPSTATE_2_3.py b/src/python_testing/TC_RVCOPSTATE_2_3.py
index 1b52211..60bbed1 100644
--- a/src/python_testing/TC_RVCOPSTATE_2_3.py
+++ b/src/python_testing/TC_RVCOPSTATE_2_3.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_RVCOPSTATE_2_4.py b/src/python_testing/TC_RVCOPSTATE_2_4.py
index ad515db..458b3cf 100644
--- a/src/python_testing/TC_RVCOPSTATE_2_4.py
+++ b/src/python_testing/TC_RVCOPSTATE_2_4.py
@@ -39,7 +39,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_RVCRUNM_1_2.py b/src/python_testing/TC_RVCRUNM_1_2.py
index 90db160..d3040fd 100644
--- a/src/python_testing/TC_RVCRUNM_1_2.py
+++ b/src/python_testing/TC_RVCRUNM_1_2.py
@@ -39,7 +39,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_RVCRUNM_2_1.py b/src/python_testing/TC_RVCRUNM_2_1.py
index 55c37c7..850faf0 100644
--- a/src/python_testing/TC_RVCRUNM_2_1.py
+++ b/src/python_testing/TC_RVCRUNM_2_1.py
@@ -41,7 +41,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
# This test requires several additional command line arguments
diff --git a/src/python_testing/TC_RVCRUNM_2_2.py b/src/python_testing/TC_RVCRUNM_2_2.py
index e78d6d7..f53a755 100644
--- a/src/python_testing/TC_RVCRUNM_2_2.py
+++ b/src/python_testing/TC_RVCRUNM_2_2.py
@@ -41,7 +41,7 @@
import enum
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
# This test requires several additional command line arguments.
diff --git a/src/python_testing/TC_SC_3_6.py b/src/python_testing/TC_SC_3_6.py
index 8cfbee8..74c09e2 100644
--- a/src/python_testing/TC_SC_3_6.py
+++ b/src/python_testing/TC_SC_3_6.py
@@ -45,8 +45,8 @@
import chip.clusters as Clusters
from chip.clusters import ClusterObjects as ClustersObjects
from chip.clusters.Attribute import SubscriptionTransaction, TypedAttributePath
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
from chip.utils import CommissioningBuildingBlocks
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
# TODO: Overall, we need to add validation that session IDs have not changed throughout to be agnostic
diff --git a/src/python_testing/TC_SC_7_1.py b/src/python_testing/TC_SC_7_1.py
index 315790e..19229b3 100644
--- a/src/python_testing/TC_SC_7_1.py
+++ b/src/python_testing/TC_SC_7_1.py
@@ -38,13 +38,12 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
def _trusted_root_test_step(dut_num: int) -> TestStep:
- read_trusted_roots_over_pase = f'TH establishes a PASE session to DUT{
- dut_num} using the provided setup code and reads the TrustedRootCertificates attribute from the operational credentials cluster over PASE'
+ read_trusted_roots_over_pase = f'TH establishes a PASE session to DUT{dut_num} using the provided setup code and reads the TrustedRootCertificates attribute from the operational credentials cluster over PASE'
return TestStep(dut_num, read_trusted_roots_over_pase, "List should be empty as the DUT should be in factory reset ")
diff --git a/src/python_testing/TC_SEAR_1_2.py b/src/python_testing/TC_SEAR_1_2.py
index 4177380..41482be 100644
--- a/src/python_testing/TC_SEAR_1_2.py
+++ b/src/python_testing/TC_SEAR_1_2.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_SEAR_1_3.py b/src/python_testing/TC_SEAR_1_3.py
index b55e21d..9592bce 100644
--- a/src/python_testing/TC_SEAR_1_3.py
+++ b/src/python_testing/TC_SEAR_1_3.py
@@ -41,7 +41,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
@@ -139,8 +139,7 @@
await self.send_cmd_select_areas_expect_response(step=9, new_areas=valid_areas, expected_response=Clusters.ServiceArea.Enums.SelectAreasStatus.kInvalidInMode)
if self.check_pics("SEAR.S.M.VALID_STATE_FOR_SELECT_AREAS") and self.check_pics("SEAR.S.M.HAS_MANUAL_SELAREA_STATE_CONTROL"):
- test_step = f"Manually intervene to put the device in a state that allows it to execute the SelectAreas({
- valid_areas}) command"
+ test_step = f"Manually intervene to put the device in a state that allows it to execute the SelectAreas({valid_areas}) command"
self.print_step("10", test_step)
if self.is_ci:
self.write_to_app_pipe({"Name": "Reset"})
@@ -156,8 +155,7 @@
await self.send_cmd_select_areas_expect_response(step=13, new_areas=valid_areas, expected_response=Clusters.ServiceArea.Enums.SelectAreasStatus.kSuccess)
if self.check_pics("SEAR.S.M.VALID_STATE_FOR_SELECT_AREAS") and self.check_pics("SEAR.S.M.HAS_MANUAL_SELAREA_STATE_CONTROL") and self.check_pics("SEAR.S.M.SELECT_AREAS_WHILE_NON_IDLE"):
- test_step = f"Manually intervene to put the device in a state that allows it to execute the SelectAreas({
- valid_areas}) command, and put the device in a non-idle state"
+ test_step = f"Manually intervene to put the device in a state that allows it to execute the SelectAreas({valid_areas}) command, and put the device in a non-idle state"
self.print_step("14", test_step)
if self.is_ci:
self.write_to_app_pipe({"Name": "Reset"})
diff --git a/src/python_testing/TC_SEAR_1_4.py b/src/python_testing/TC_SEAR_1_4.py
index cf53f44..3f3a84b 100644
--- a/src/python_testing/TC_SEAR_1_4.py
+++ b/src/python_testing/TC_SEAR_1_4.py
@@ -40,7 +40,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_SEAR_1_5.py b/src/python_testing/TC_SEAR_1_5.py
index 130ccb8..99da6da 100644
--- a/src/python_testing/TC_SEAR_1_5.py
+++ b/src/python_testing/TC_SEAR_1_5.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_SEAR_1_6.py b/src/python_testing/TC_SEAR_1_6.py
index dc6188a..434da00 100644
--- a/src/python_testing/TC_SEAR_1_6.py
+++ b/src/python_testing/TC_SEAR_1_6.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_SWTCH.py b/src/python_testing/TC_SWTCH.py
index 3c764c6..7cafaa7 100644
--- a/src/python_testing/TC_SWTCH.py
+++ b/src/python_testing/TC_SWTCH.py
@@ -90,10 +90,10 @@
import test_plan_support
from chip.clusters import ClusterObjects as ClusterObjects
from chip.clusters.Attribute import EventReadResult
-from chip.testing.matter_testing import (AttributeValue, ClusterAttributeChangeAccumulator, EventChangeCallback, MatterBaseTest,
- TestStep, await_sequence_of_reports, default_matter_test_main, has_feature,
- run_if_endpoint_matches)
from chip.tlv import uint
+from matter_testing_support import (AttributeValue, ClusterAttributeChangeAccumulator, EventChangeCallback, MatterBaseTest,
+ TestStep, await_sequence_of_reports, default_matter_test_main, has_feature,
+ run_if_endpoint_matches)
from mobly import asserts
logger = logging.getLogger(__name__)
@@ -281,8 +281,7 @@
elapsed = 0.0
time_remaining = timeout_sec
- logging.info(f"Waiting {timeout_sec: .1f} seconds for no more events for cluster {
- expected_cluster} on endpoint {endpoint_id}")
+ logging.info(f"Waiting {timeout_sec:.1f} seconds for no more events for cluster {expected_cluster} on endpoint {endpoint_id}")
while time_remaining > 0:
try:
item: EventReadResult = event_queue.get(block=True, timeout=time_remaining)
diff --git a/src/python_testing/TC_TIMESYNC_2_1.py b/src/python_testing/TC_TIMESYNC_2_1.py
index cb2df9d..9858976 100644
--- a/src/python_testing/TC_TIMESYNC_2_1.py
+++ b/src/python_testing/TC_TIMESYNC_2_1.py
@@ -41,8 +41,8 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import (MatterBaseTest, default_matter_test_main, has_attribute, has_cluster,
- run_if_endpoint_matches, utc_time_in_matter_epoch)
+from matter_testing_support import (MatterBaseTest, default_matter_test_main, has_attribute, has_cluster, run_if_endpoint_matches,
+ utc_time_in_matter_epoch)
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_10.py b/src/python_testing/TC_TIMESYNC_2_10.py
index 99ca9f3..b9aa7da 100644
--- a/src/python_testing/TC_TIMESYNC_2_10.py
+++ b/src/python_testing/TC_TIMESYNC_2_10.py
@@ -43,9 +43,9 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main,
- utc_time_in_matter_epoch)
from chip.tlv import uint
+from matter_testing_support import (MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main,
+ utc_time_in_matter_epoch)
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_11.py b/src/python_testing/TC_TIMESYNC_2_11.py
index 0865bc8..1aaed7a 100644
--- a/src/python_testing/TC_TIMESYNC_2_11.py
+++ b/src/python_testing/TC_TIMESYNC_2_11.py
@@ -43,9 +43,9 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main,
- get_wait_seconds_from_set_time, type_matches, utc_time_in_matter_epoch)
from chip.tlv import uint
+from matter_testing_support import (MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main,
+ get_wait_seconds_from_set_time, type_matches, utc_time_in_matter_epoch)
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_12.py b/src/python_testing/TC_TIMESYNC_2_12.py
index 7677dcf..cd4378f 100644
--- a/src/python_testing/TC_TIMESYNC_2_12.py
+++ b/src/python_testing/TC_TIMESYNC_2_12.py
@@ -43,9 +43,9 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main,
- get_wait_seconds_from_set_time, type_matches, utc_time_in_matter_epoch)
from chip.tlv import uint
+from matter_testing_support import (MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main,
+ get_wait_seconds_from_set_time, type_matches, utc_time_in_matter_epoch)
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_13.py b/src/python_testing/TC_TIMESYNC_2_13.py
index 8138983..91c679e 100644
--- a/src/python_testing/TC_TIMESYNC_2_13.py
+++ b/src/python_testing/TC_TIMESYNC_2_13.py
@@ -41,7 +41,7 @@
import chip.clusters as Clusters
from chip import ChipDeviceCtrl
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, SimpleEventCallback, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_2.py b/src/python_testing/TC_TIMESYNC_2_2.py
index 74f935a..dff4bd5 100644
--- a/src/python_testing/TC_TIMESYNC_2_2.py
+++ b/src/python_testing/TC_TIMESYNC_2_2.py
@@ -40,8 +40,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main,
- utc_time_in_matter_epoch)
+from matter_testing_support import MatterBaseTest, async_test_body, compare_time, default_matter_test_main, utc_time_in_matter_epoch
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_4.py b/src/python_testing/TC_TIMESYNC_2_4.py
index 76fe907..a367dca 100644
--- a/src/python_testing/TC_TIMESYNC_2_4.py
+++ b/src/python_testing/TC_TIMESYNC_2_4.py
@@ -40,8 +40,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import (MatterBaseTest, async_test_body, default_matter_test_main, type_matches,
- utc_time_in_matter_epoch)
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches, utc_time_in_matter_epoch
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_5.py b/src/python_testing/TC_TIMESYNC_2_5.py
index f363f03..d62797e 100644
--- a/src/python_testing/TC_TIMESYNC_2_5.py
+++ b/src/python_testing/TC_TIMESYNC_2_5.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, utc_time_in_matter_epoch
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, utc_time_in_matter_epoch
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_6.py b/src/python_testing/TC_TIMESYNC_2_6.py
index 0e9ec9f..f6fe873 100644
--- a/src/python_testing/TC_TIMESYNC_2_6.py
+++ b/src/python_testing/TC_TIMESYNC_2_6.py
@@ -40,7 +40,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import Nullable, NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_7.py b/src/python_testing/TC_TIMESYNC_2_7.py
index 1c6cea2..edc7154 100644
--- a/src/python_testing/TC_TIMESYNC_2_7.py
+++ b/src/python_testing/TC_TIMESYNC_2_7.py
@@ -42,9 +42,9 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main, type_matches,
- utc_time_in_matter_epoch)
from chip.tlv import uint
+from matter_testing_support import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main, type_matches,
+ utc_time_in_matter_epoch)
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_8.py b/src/python_testing/TC_TIMESYNC_2_8.py
index 82a77c4..0778534 100644
--- a/src/python_testing/TC_TIMESYNC_2_8.py
+++ b/src/python_testing/TC_TIMESYNC_2_8.py
@@ -42,9 +42,9 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main, type_matches,
- utc_time_in_matter_epoch)
from chip.tlv import uint
+from matter_testing_support import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main, type_matches,
+ utc_time_in_matter_epoch)
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_2_9.py b/src/python_testing/TC_TIMESYNC_2_9.py
index 4ce83f8..1f439b8 100644
--- a/src/python_testing/TC_TIMESYNC_2_9.py
+++ b/src/python_testing/TC_TIMESYNC_2_9.py
@@ -41,9 +41,9 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main, type_matches,
- utc_time_in_matter_epoch)
from chip.tlv import uint
+from matter_testing_support import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main, type_matches,
+ utc_time_in_matter_epoch)
from mobly import asserts
diff --git a/src/python_testing/TC_TIMESYNC_3_1.py b/src/python_testing/TC_TIMESYNC_3_1.py
index 4c7c9d9..3f292d0 100644
--- a/src/python_testing/TC_TIMESYNC_3_1.py
+++ b/src/python_testing/TC_TIMESYNC_3_1.py
@@ -35,7 +35,7 @@
# === END CI TEST ARGUMENTS ===
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_TMP_2_1.py b/src/python_testing/TC_TMP_2_1.py
index d0ae9cf..f48b969 100644
--- a/src/python_testing/TC_TMP_2_1.py
+++ b/src/python_testing/TC_TMP_2_1.py
@@ -16,7 +16,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_TSTAT_4_2.py b/src/python_testing/TC_TSTAT_4_2.py
index 6dad144..fa77f94 100644
--- a/src/python_testing/TC_TSTAT_4_2.py
+++ b/src/python_testing/TC_TSTAT_4_2.py
@@ -43,7 +43,7 @@
from chip.clusters import Globals
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
logger = logging.getLogger(__name__)
diff --git a/src/python_testing/TC_TestEventTrigger.py b/src/python_testing/TC_TestEventTrigger.py
index ae4f64a..3805354 100644
--- a/src/python_testing/TC_TestEventTrigger.py
+++ b/src/python_testing/TC_TestEventTrigger.py
@@ -43,7 +43,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
# Assumes `--enable-key 000102030405060708090a0b0c0d0e0f` on Linux app command line, or a DUT
diff --git a/src/python_testing/TC_VALCC_2_1.py b/src/python_testing/TC_VALCC_2_1.py
index d6f00b0..a079c88 100644
--- a/src/python_testing/TC_VALCC_2_1.py
+++ b/src/python_testing/TC_VALCC_2_1.py
@@ -35,7 +35,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_3_1.py b/src/python_testing/TC_VALCC_3_1.py
index 4b53ab0..f4c6ebf 100644
--- a/src/python_testing/TC_VALCC_3_1.py
+++ b/src/python_testing/TC_VALCC_3_1.py
@@ -36,7 +36,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_3_2.py b/src/python_testing/TC_VALCC_3_2.py
index 6905e3b..0609051 100644
--- a/src/python_testing/TC_VALCC_3_2.py
+++ b/src/python_testing/TC_VALCC_3_2.py
@@ -37,7 +37,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_3_3.py b/src/python_testing/TC_VALCC_3_3.py
index a63053c..d90065d 100644
--- a/src/python_testing/TC_VALCC_3_3.py
+++ b/src/python_testing/TC_VALCC_3_3.py
@@ -37,7 +37,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_3_4.py b/src/python_testing/TC_VALCC_3_4.py
index 30c57dc..f1363a5 100644
--- a/src/python_testing/TC_VALCC_3_4.py
+++ b/src/python_testing/TC_VALCC_3_4.py
@@ -35,7 +35,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_4_1.py b/src/python_testing/TC_VALCC_4_1.py
index 9af428d..a103898 100644
--- a/src/python_testing/TC_VALCC_4_1.py
+++ b/src/python_testing/TC_VALCC_4_1.py
@@ -36,7 +36,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_4_2.py b/src/python_testing/TC_VALCC_4_2.py
index 9365e5b..f2f0dd6 100644
--- a/src/python_testing/TC_VALCC_4_2.py
+++ b/src/python_testing/TC_VALCC_4_2.py
@@ -36,7 +36,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_4_3.py b/src/python_testing/TC_VALCC_4_3.py
index b0762d0..a66d4ea 100644
--- a/src/python_testing/TC_VALCC_4_3.py
+++ b/src/python_testing/TC_VALCC_4_3.py
@@ -36,7 +36,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_4_4.py b/src/python_testing/TC_VALCC_4_4.py
index b85ff9a..f6ad63d 100644
--- a/src/python_testing/TC_VALCC_4_4.py
+++ b/src/python_testing/TC_VALCC_4_4.py
@@ -36,8 +36,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import (MatterBaseTest, TestStep, async_test_body, default_matter_test_main,
- utc_time_in_matter_epoch)
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, utc_time_in_matter_epoch
from mobly import asserts
diff --git a/src/python_testing/TC_VALCC_4_5.py b/src/python_testing/TC_VALCC_4_5.py
index c6b7674..3b850c0 100644
--- a/src/python_testing/TC_VALCC_4_5.py
+++ b/src/python_testing/TC_VALCC_4_5.py
@@ -36,7 +36,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_WHM_1_2.py b/src/python_testing/TC_WHM_1_2.py
index 2bbcdd5..9d7d9b2 100644
--- a/src/python_testing/TC_WHM_1_2.py
+++ b/src/python_testing/TC_WHM_1_2.py
@@ -41,7 +41,7 @@
import logging
import chip.clusters as Clusters
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TC_WHM_2_1.py b/src/python_testing/TC_WHM_2_1.py
index b9dcb02..6172ee0 100644
--- a/src/python_testing/TC_WHM_2_1.py
+++ b/src/python_testing/TC_WHM_2_1.py
@@ -43,7 +43,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
diff --git a/src/python_testing/TC_pics_checker.py b/src/python_testing/TC_pics_checker.py
index 07e8613..91e2102 100644
--- a/src/python_testing/TC_pics_checker.py
+++ b/src/python_testing/TC_pics_checker.py
@@ -17,13 +17,13 @@
import math
import chip.clusters as Clusters
-from chip.testing.basic_composition import BasicCompositionTests
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, FeaturePathLocation,
- MatterBaseTest, ProblemLocation, TestStep, async_test_body, default_matter_test_main)
-from chip.testing.pics import accepted_cmd_pics_str, attribute_pics_str, feature_pics_str, generated_cmd_pics_str
-from chip.testing.spec_parsing import build_xml_clusters
+from basic_composition_support import BasicCompositionTests
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, FeaturePathLocation,
+ MatterBaseTest, ProblemLocation, TestStep, async_test_body, default_matter_test_main)
from mobly import asserts
+from pics_support import accepted_cmd_pics_str, attribute_pics_str, feature_pics_str, generated_cmd_pics_str
+from spec_parsing_support import build_xml_clusters
class TC_PICS_Checker(MatterBaseTest, BasicCompositionTests):
diff --git a/src/python_testing/TestBatchInvoke.py b/src/python_testing/TestBatchInvoke.py
index 6465692..a17f7b8 100644
--- a/src/python_testing/TestBatchInvoke.py
+++ b/src/python_testing/TestBatchInvoke.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, type_matches
from mobly import asserts
''' Integration test of batch commands using UnitTesting Cluster
diff --git a/src/python_testing/TestChoiceConformanceSupport.py b/src/python_testing/TestChoiceConformanceSupport.py
index 77eca93..8436bc8 100644
--- a/src/python_testing/TestChoiceConformanceSupport.py
+++ b/src/python_testing/TestChoiceConformanceSupport.py
@@ -19,11 +19,11 @@
import xml.etree.ElementTree as ElementTree
import jinja2
-from chip.testing.choice_conformance import (evaluate_attribute_choice_conformance, evaluate_command_choice_conformance,
- evaluate_feature_choice_conformance)
-from chip.testing.matter_testing import MatterBaseTest, ProblemNotice, default_matter_test_main
-from chip.testing.spec_parsing import XmlCluster, add_cluster_data_from_xml
+from choice_conformance_support import (evaluate_attribute_choice_conformance, evaluate_command_choice_conformance,
+ evaluate_feature_choice_conformance)
+from matter_testing_support import MatterBaseTest, ProblemNotice, default_matter_test_main
from mobly import asserts
+from spec_parsing_support import XmlCluster, add_cluster_data_from_xml
FEATURE_TEMPLATE = '''\
<feature bit="{{ id }}" code="{{ name }}" name="{{ name }}" summary="summary">
diff --git a/src/python_testing/TestCommissioningTimeSync.py b/src/python_testing/TestCommissioningTimeSync.py
index d4033ea..dfd03d9 100644
--- a/src/python_testing/TestCommissioningTimeSync.py
+++ b/src/python_testing/TestCommissioningTimeSync.py
@@ -20,7 +20,7 @@
from chip import ChipDeviceCtrl
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main, utc_time_in_matter_epoch
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main, utc_time_in_matter_epoch
from mobly import asserts
# We don't have a good pipe between the c++ enums in CommissioningDelegate and python
diff --git a/src/python_testing/TestConformanceSupport.py b/src/python_testing/TestConformanceSupport.py
index ca41bf0..3744b6f 100644
--- a/src/python_testing/TestConformanceSupport.py
+++ b/src/python_testing/TestConformanceSupport.py
@@ -18,11 +18,11 @@
import xml.etree.ElementTree as ElementTree
from typing import Callable
-from chip.testing.conformance import (Choice, Conformance, ConformanceDecision, ConformanceException, ConformanceParseParameters,
- deprecated, disallowed, mandatory, optional, parse_basic_callable_from_xml,
- parse_callable_from_xml, parse_device_type_callable_from_xml, provisional, zigbee)
-from chip.testing.matter_testing import MatterBaseTest, default_matter_test_main
from chip.tlv import uint
+from conformance_support import (Choice, Conformance, ConformanceDecision, ConformanceException, ConformanceParseParameters,
+ deprecated, disallowed, mandatory, optional, parse_basic_callable_from_xml,
+ parse_callable_from_xml, parse_device_type_callable_from_xml, provisional, zigbee)
+from matter_testing_support import MatterBaseTest, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TestConformanceTest.py b/src/python_testing/TestConformanceTest.py
index ddf3e42..f0ff803 100644
--- a/src/python_testing/TestConformanceTest.py
+++ b/src/python_testing/TestConformanceTest.py
@@ -18,12 +18,12 @@
from typing import Any
import chip.clusters as Clusters
-from chip.testing.basic_composition import arls_populated
-from chip.testing.conformance import ConformanceDecision
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
-from chip.testing.spec_parsing import build_xml_clusters, build_xml_device_types
+from basic_composition_support import arls_populated
+from conformance_support import ConformanceDecision
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
+from spec_parsing_support import build_xml_clusters, build_xml_device_types
from TC_DeviceConformance import DeviceConformanceTests
diff --git a/src/python_testing/TestGroupTableReports.py b/src/python_testing/TestGroupTableReports.py
index 9d98a05..6e3980b 100644
--- a/src/python_testing/TestGroupTableReports.py
+++ b/src/python_testing/TestGroupTableReports.py
@@ -42,7 +42,7 @@
from chip.clusters import ClusterObjects as ClusterObjects
from chip.clusters.Attribute import SubscriptionTransaction, TypedAttributePath
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TestIdChecks.py b/src/python_testing/TestIdChecks.py
index eda01ef..8969807 100644
--- a/src/python_testing/TestIdChecks.py
+++ b/src/python_testing/TestIdChecks.py
@@ -15,10 +15,9 @@
# limitations under the License.
#
-from chip.testing.global_attribute_ids import (AttributeIdType, ClusterIdType, DeviceTypeIdType, attribute_id_type, cluster_id_type,
- device_type_id_type, is_valid_attribute_id, is_valid_cluster_id,
- is_valid_device_type_id)
-from chip.testing.matter_testing import MatterBaseTest, default_matter_test_main
+from global_attribute_ids import (AttributeIdType, ClusterIdType, DeviceTypeIdType, attribute_id_type, cluster_id_type,
+ device_type_id_type, is_valid_attribute_id, is_valid_cluster_id, is_valid_device_type_id)
+from matter_testing_support import MatterBaseTest, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/TestMatterTestingSupport.py b/src/python_testing/TestMatterTestingSupport.py
index 811349b..08c3e83 100644
--- a/src/python_testing/TestMatterTestingSupport.py
+++ b/src/python_testing/TestMatterTestingSupport.py
@@ -22,15 +22,14 @@
import chip.clusters as Clusters
from chip.clusters.Types import Nullable, NullValue
-from chip.testing.matter_testing import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main,
- get_wait_seconds_from_set_time, parse_matter_test_args, type_matches,
- utc_time_in_matter_epoch)
-from chip.testing.pics import parse_pics, parse_pics_xml
-from chip.testing.taglist_and_topology_test import (TagProblem, create_device_type_list_for_root, create_device_type_lists,
- find_tag_list_problems, find_tree_roots, flat_list_ok, get_all_children,
- get_direct_children_of_root, parts_list_cycles, separate_endpoint_types)
from chip.tlv import uint
+from matter_testing_support import (MatterBaseTest, async_test_body, compare_time, default_matter_test_main,
+ get_wait_seconds_from_set_time, parse_matter_test_args, type_matches, utc_time_in_matter_epoch)
from mobly import asserts, signals
+from pics_support import parse_pics, parse_pics_xml
+from taglist_and_topology_test_support import (TagProblem, create_device_type_list_for_root, create_device_type_lists,
+ find_tag_list_problems, find_tree_roots, flat_list_ok, get_all_children,
+ get_direct_children_of_root, parts_list_cycles, separate_endpoint_types)
def get_raw_type_list():
diff --git a/src/python_testing/TestSpecParsingDeviceType.py b/src/python_testing/TestSpecParsingDeviceType.py
index a9ee14f..7729cce 100644
--- a/src/python_testing/TestSpecParsingDeviceType.py
+++ b/src/python_testing/TestSpecParsingDeviceType.py
@@ -18,12 +18,12 @@
import chip.clusters as Clusters
from chip.clusters import Attribute
-from chip.testing.conformance import conformance_allowed
-from chip.testing.matter_testing import MatterBaseTest, default_matter_test_main
-from chip.testing.spec_parsing import build_xml_clusters, build_xml_device_types, parse_single_device_type
from chip.tlv import uint
+from conformance_support import conformance_allowed
from jinja2 import Template
+from matter_testing_support import MatterBaseTest, default_matter_test_main
from mobly import asserts
+from spec_parsing_support import build_xml_clusters, build_xml_device_types, parse_single_device_type
from TC_DeviceConformance import DeviceConformanceTests
diff --git a/src/python_testing/TestSpecParsingSupport.py b/src/python_testing/TestSpecParsingSupport.py
index b4c908c..4e0171b 100644
--- a/src/python_testing/TestSpecParsingSupport.py
+++ b/src/python_testing/TestSpecParsingSupport.py
@@ -15,16 +15,17 @@
# limitations under the License.
#
+import os
import xml.etree.ElementTree as ElementTree
import chip.clusters as Clusters
import jinja2
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import MatterBaseTest, ProblemNotice, default_matter_test_main
-from chip.testing.spec_parsing import (ClusterParser, DataModelLevel, PrebuiltDataModelDirectory, SpecParsingException, XmlCluster,
- add_cluster_data_from_xml, build_xml_clusters, check_clusters_for_unknown_commands,
- combine_derived_clusters_with_base, get_data_model_directory)
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import MatterBaseTest, ProblemNotice, default_matter_test_main
from mobly import asserts
+from spec_parsing_support import (ClusterParser, PrebuiltDataModelDirectory, SpecParsingException, XmlCluster,
+ add_cluster_data_from_xml, build_xml_clusters, check_clusters_for_unknown_commands,
+ combine_derived_clusters_with_base)
# TODO: improve the test coverage here
# https://github.com/project-chip/connectedhomeip/issues/30958
@@ -271,10 +272,10 @@
asserts.assert_equal(set(one_four_clusters.keys())-set(tot_xml_clusters.keys()),
set(), "There are some 1.4 clusters that are not included in the TOT spec")
- str_path = get_data_model_directory(PrebuiltDataModelDirectory.k1_4, DataModelLevel.kCluster)
+ str_path = str(os.path.join(os.path.dirname(os.path.realpath(__file__)),
+ '..', '..', 'data_model', '1.4', 'clusters'))
string_override_check, problems = build_xml_clusters(str_path)
-
- asserts.assert_count_equal(string_override_check.keys(), self.spec_xml_clusters.keys(), "Mismatched cluster generation")
+ asserts.assert_equal(string_override_check.keys(), self.spec_xml_clusters.keys(), "Mismatched cluster generation")
with asserts.assert_raises(SpecParsingException):
build_xml_clusters("baddir")
diff --git a/src/python_testing/TestTimeSyncTrustedTimeSource.py b/src/python_testing/TestTimeSyncTrustedTimeSource.py
index 50bca6f..2f4c9a1 100644
--- a/src/python_testing/TestTimeSyncTrustedTimeSource.py
+++ b/src/python_testing/TestTimeSyncTrustedTimeSource.py
@@ -18,7 +18,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
# We don't have a good pipe between the c++ enums in CommissioningDelegate and python
diff --git a/src/python_testing/TestUnitTestingErrorPath.py b/src/python_testing/TestUnitTestingErrorPath.py
index 872f1fa..70d7b96 100644
--- a/src/python_testing/TestUnitTestingErrorPath.py
+++ b/src/python_testing/TestUnitTestingErrorPath.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main
from mobly import asserts
""" Integration test for error path returns via the UnitTesting cluster.
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/basic_composition.py b/src/python_testing/basic_composition_support.py
similarity index 100%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/basic_composition.py
rename to src/python_testing/basic_composition_support.py
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/choice_conformance.py b/src/python_testing/choice_conformance_support.py
similarity index 92%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/choice_conformance.py
rename to src/python_testing/choice_conformance_support.py
index 7e7775d..58d37bf 100644
--- a/src/python_testing/matter_testing_infrastructure/chip/testing/choice_conformance.py
+++ b/src/python_testing/choice_conformance_support.py
@@ -1,8 +1,8 @@
-from chip.testing.conformance import Choice, ConformanceDecisionWithChoice
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import AttributePathLocation, ProblemNotice, ProblemSeverity
-from chip.testing.spec_parsing import XmlCluster
from chip.tlv import uint
+from conformance_support import Choice, ConformanceDecisionWithChoice
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import AttributePathLocation, ProblemNotice, ProblemSeverity
+from spec_parsing_support import XmlCluster
class ChoiceConformanceProblemNotice(ProblemNotice):
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/conformance.py b/src/python_testing/conformance_support.py
similarity index 100%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/conformance.py
rename to src/python_testing/conformance_support.py
diff --git a/src/python_testing/drlk_2_x_common.py b/src/python_testing/drlk_2_x_common.py
index cdd1382..92c0ab2 100644
--- a/src/python_testing/drlk_2_x_common.py
+++ b/src/python_testing/drlk_2_x_common.py
@@ -23,7 +23,7 @@
import chip.clusters as Clusters
from chip.clusters.Types import NullValue
from chip.interaction_model import InteractionModelError, Status
-from chip.testing.matter_testing import type_matches
+from matter_testing_support import type_matches
from mobly import asserts
diff --git a/src/python_testing/execute_python_tests.py b/src/python_testing/execute_python_tests.py
index 34a3918..4e67821 100644
--- a/src/python_testing/execute_python_tests.py
+++ b/src/python_testing/execute_python_tests.py
@@ -53,7 +53,7 @@
# Define the base command to run tests
base_command = os.path.join(chip_root, "scripts/tests/run_python_test.py")
- # Define the test python script files and patterns to exclude
+ # Define the files and patterns to exclude
excluded_patterns = {
"MinimalRepresentation.py", # Code/Test not being used or not shared code for any other tests
"TC_CNET_4_4.py", # It has no CI execution block, is not executed in CI
@@ -84,6 +84,14 @@
"hello_test.py", # Is a template for tests
"test_plan_support.py", # Shared code for TC_*, not a standalone test
"test_plan_table_generator.py", # Code/Test not being used or not shared code for any other tests
+ "basic_composition_support.py", # Test support/shared code script, not a standalone test
+ "choice_conformance_support.py", # Test support/shared code script, not a standalone test
+ "conformance_support.py", # Test support/shared code script, not a standalone test
+ "global_attribute_ids.py", # Test support/shared code script, not a standalone test
+ "matter_testing_support.py", # Test support/shared code script, not a standalone test
+ "pics_support.py", # Test support/shared code script, not a standalone test
+ "spec_parsing_support.py", # Test support/shared code script, not a standalone test
+ "taglist_and_topology_test_support.py" # Test support/shared code script, not a standalone test
}
# Get all .py files in the directory
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/global_attribute_ids.py b/src/python_testing/global_attribute_ids.py
similarity index 100%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/global_attribute_ids.py
rename to src/python_testing/global_attribute_ids.py
diff --git a/src/python_testing/hello_external_runner.py b/src/python_testing/hello_external_runner.py
index 64af55c..5f00eeb 100755
--- a/src/python_testing/hello_external_runner.py
+++ b/src/python_testing/hello_external_runner.py
@@ -23,8 +23,8 @@
from multiprocessing import Process
from multiprocessing.managers import BaseManager
-from chip.testing.matter_testing import MatterTestConfig, get_test_info, run_tests
from hello_test import HelloTest
+from matter_testing_support import MatterTestConfig, get_test_info, run_tests
try:
from matter_yamltests.hooks import TestRunnerHooks
diff --git a/src/python_testing/hello_test.py b/src/python_testing/hello_test.py
index 2d910b1..0793ee3 100644
--- a/src/python_testing/hello_test.py
+++ b/src/python_testing/hello_test.py
@@ -38,7 +38,7 @@
import chip.clusters as Clusters
from chip.interaction_model import Status
-from chip.testing.matter_testing import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
+from matter_testing_support import MatterBaseTest, TestStep, async_test_body, default_matter_test_main
from mobly import asserts
diff --git a/src/python_testing/matter_testing_infrastructure/BUILD.gn b/src/python_testing/matter_testing_infrastructure/BUILD.gn
index 19c7aee..41bbcef 100644
--- a/src/python_testing/matter_testing_infrastructure/BUILD.gn
+++ b/src/python_testing/matter_testing_infrastructure/BUILD.gn
@@ -18,6 +18,7 @@
import("//build_overrides/pigweed.gni")
import("$dir_pw_build/python.gni")
+# Python package for CHIP testing support.
pw_python_package("chip-testing") {
setup = [
"setup.py",
@@ -30,15 +31,7 @@
sources = [
"chip/testing/__init__.py",
"chip/testing/apps.py",
- "chip/testing/basic_composition.py",
- "chip/testing/choice_conformance.py",
- "chip/testing/conformance.py",
- "chip/testing/global_attribute_ids.py",
- "chip/testing/matter_testing.py",
"chip/testing/metadata.py",
- "chip/testing/pics.py",
- "chip/testing/spec_parsing.py",
- "chip/testing/taglist_and_topology_test.py",
"chip/testing/tasks.py",
]
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/apps.py b/src/python_testing/matter_testing_infrastructure/chip/testing/apps.py
index 3b21a1c..af56efc 100644
--- a/src/python_testing/matter_testing_infrastructure/chip/testing/apps.py
+++ b/src/python_testing/matter_testing_infrastructure/chip/testing/apps.py
@@ -16,7 +16,7 @@
import signal
import tempfile
-from chip.testing.tasks import Subprocess
+from .tasks import Subprocess
class AppServerSubprocess(Subprocess):
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/matter_testing.py b/src/python_testing/matter_testing_support.py
similarity index 98%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/matter_testing.py
rename to src/python_testing/matter_testing_support.py
index 2d23a9f..2e153a3 100644
--- a/src/python_testing/matter_testing_infrastructure/chip/testing/matter_testing.py
+++ b/src/python_testing/matter_testing_support.py
@@ -65,12 +65,12 @@
from chip.interaction_model import InteractionModelError, Status
from chip.setup_payload import SetupPayload
from chip.storage import PersistentStorage
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.pics import read_pics_from_file
from chip.tracing import TracingContext
+from global_attribute_ids import GlobalAttributeIds
from mobly import asserts, base_test, signals, utils
from mobly.config_parser import ENV_MOBLY_LOGPATH, TestRunConfig
from mobly.test_runner import TestRunner
+from pics_support import read_pics_from_file
try:
from matter_yamltests.hooks import TestRunnerHooks
@@ -2278,7 +2278,7 @@
In this case, only one test class in a test script is allowed.
To make your test script executable, add the following to your file:
.. code-block:: python
- from chip.testing.matter_testing.py import default_matter_test_main
+ from matter_testing_support.py import default_matter_test_main
...
if __name__ == '__main__':
default_matter_test_main.main()
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/pics.py b/src/python_testing/pics_support.py
similarity index 100%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/pics.py
rename to src/python_testing/pics_support.py
diff --git a/src/python_testing/post_certification_tests/production_device_checks.py b/src/python_testing/post_certification_tests/production_device_checks.py
index b8e567f..e4262a0 100644
--- a/src/python_testing/post_certification_tests/production_device_checks.py
+++ b/src/python_testing/post_certification_tests/production_device_checks.py
@@ -59,15 +59,15 @@
os.path.join(os.path.dirname(__file__), '..', '..', '..'))
try:
- from chip.testing.basic_composition import BasicCompositionTests
- from chip.testing.matter_testing import (MatterBaseTest, MatterStackState, MatterTestConfig, TestStep, async_test_body,
- run_tests_no_exit)
+ from basic_composition_support import BasicCompositionTests
+ from matter_testing_support import (MatterBaseTest, MatterStackState, MatterTestConfig, TestStep, async_test_body,
+ run_tests_no_exit)
except ImportError:
sys.path.append(os.path.abspath(
os.path.join(os.path.dirname(__file__), '..')))
- from chip.testing.basic_composition import BasicCompositionTests
- from chip.testing.matter_testing import (MatterBaseTest, MatterStackState, MatterTestConfig, TestStep, async_test_body,
- run_tests_no_exit)
+ from basic_composition_support import BasicCompositionTests
+ from matter_testing_support import (MatterBaseTest, MatterStackState, MatterTestConfig, TestStep, async_test_body,
+ run_tests_no_exit)
try:
import fetch_paa_certs_from_dcl
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/spec_parsing.py b/src/python_testing/spec_parsing_support.py
similarity index 94%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/spec_parsing.py
rename to src/python_testing/spec_parsing_support.py
index 97a1360..75ffea1 100644
--- a/src/python_testing/matter_testing_infrastructure/chip/testing/spec_parsing.py
+++ b/src/python_testing/spec_parsing_support.py
@@ -26,14 +26,14 @@
from typing import Callable, Optional
import chip.clusters as Clusters
-import chip.testing.conformance as conformance_support
-from chip.testing.conformance import (OPTIONAL_CONFORM, TOP_LEVEL_CONFORMANCE_TAGS, ConformanceDecision, ConformanceException,
- ConformanceParseParameters, feature, is_disallowed, mandatory, optional, or_operation,
- parse_callable_from_xml, parse_device_type_callable_from_xml)
-from chip.testing.global_attribute_ids import GlobalAttributeIds
-from chip.testing.matter_testing import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, DeviceTypePathLocation,
- EventPathLocation, FeaturePathLocation, ProblemNotice, ProblemSeverity)
+import conformance_support
from chip.tlv import uint
+from conformance_support import (OPTIONAL_CONFORM, TOP_LEVEL_CONFORMANCE_TAGS, ConformanceDecision, ConformanceException,
+ ConformanceParseParameters, feature, is_disallowed, mandatory, optional, or_operation,
+ parse_callable_from_xml, parse_device_type_callable_from_xml)
+from global_attribute_ids import GlobalAttributeIds
+from matter_testing_support import (AttributePathLocation, ClusterPathLocation, CommandPathLocation, DeviceTypePathLocation,
+ EventPathLocation, FeaturePathLocation, ProblemNotice, ProblemSeverity)
_PRIVILEGE_STR = {
None: "N/A",
@@ -518,36 +518,19 @@
kDeviceType = 'device_types'
-def _get_data_model_root() -> str:
- """Attempts to find ${CHIP_ROOT}/data_model or equivalent."""
-
- # Since this class is generally in a module, we have to rely on being bootstrapped or
- # we use CWD if we cannot
- choices = [os.getcwd()]
-
- if 'PW_PROJECT_ROOT' in os.environ:
- choices.insert(0, os.environ['PW_PROJECT_ROOT'])
-
- for c in choices:
- data_model_path = os.path.join(c, 'data_model')
- if os.path.exists(os.path.join(data_model_path, 'master', 'scraper_version')):
- return data_model_path
- raise FileNotFoundError('Cannot find a CHIP_ROOT/data_model path. Tried %r as prefixes.' % choices)
-
-
-def get_data_model_directory(data_model_directory: typing.Union[PrebuiltDataModelDirectory, str], data_model_level: DataModelLevel) -> str:
+def _get_data_model_directory(data_model_directory: typing.Union[PrebuiltDataModelDirectory, str], data_model_level: DataModelLevel) -> str:
if data_model_directory == PrebuiltDataModelDirectory.k1_3:
- return os.path.join(_get_data_model_root(), '1.3', data_model_level)
+ return os.path.join(os.path.dirname(os.path.realpath(__file__)), '..', '..', 'data_model', '1.3', data_model_level)
elif data_model_directory == PrebuiltDataModelDirectory.k1_4:
- return os.path.join(_get_data_model_root(), '1.4', data_model_level)
+ return os.path.join(os.path.dirname(os.path.realpath(__file__)), '..', '..', 'data_model', '1.4', data_model_level)
elif data_model_directory == PrebuiltDataModelDirectory.kMaster:
- return os.path.join(_get_data_model_root(), 'master', data_model_level)
+ return os.path.join(os.path.dirname(os.path.realpath(__file__)), '..', '..', 'data_model', 'master', data_model_level)
else:
return data_model_directory
def build_xml_clusters(data_model_directory: typing.Union[PrebuiltDataModelDirectory, str] = PrebuiltDataModelDirectory.k1_4) -> tuple[dict[uint, XmlCluster], list[ProblemNotice]]:
- dir = get_data_model_directory(data_model_directory, DataModelLevel.kCluster)
+ dir = _get_data_model_directory(data_model_directory, DataModelLevel.kCluster)
clusters: dict[int, XmlCluster] = {}
pure_base_clusters: dict[str, XmlCluster] = {}
@@ -794,7 +777,7 @@
def build_xml_device_types(data_model_directory: typing.Union[PrebuiltDataModelDirectory, str] = PrebuiltDataModelDirectory.k1_4) -> tuple[dict[int, XmlDeviceType], list[ProblemNotice]]:
- dir = get_data_model_directory(data_model_directory, DataModelLevel.kDeviceType)
+ dir = _get_data_model_directory(data_model_directory, DataModelLevel.kDeviceType)
device_types: dict[int, XmlDeviceType] = {}
problems = []
for xml in glob.glob(f"{dir}/*.xml"):
diff --git a/src/python_testing/matter_testing_infrastructure/chip/testing/taglist_and_topology_test.py b/src/python_testing/taglist_and_topology_test_support.py
similarity index 100%
rename from src/python_testing/matter_testing_infrastructure/chip/testing/taglist_and_topology_test.py
rename to src/python_testing/taglist_and_topology_test_support.py
diff --git a/src/python_testing/test_plan_table_generator.py b/src/python_testing/test_plan_table_generator.py
index b38f6f9..c972116 100755
--- a/src/python_testing/test_plan_table_generator.py
+++ b/src/python_testing/test_plan_table_generator.py
@@ -22,7 +22,7 @@
from pathlib import Path
import click
-from chip.testing.matter_testing import MatterTestConfig, generate_mobly_test_config
+from matter_testing_support import MatterTestConfig, generate_mobly_test_config
def indent_multiline(multiline: str, num_spaces: int) -> str:
diff --git a/src/python_testing/test_testing/MockTestRunner.py b/src/python_testing/test_testing/MockTestRunner.py
index 6c9bc1c..2d0afb8 100644
--- a/src/python_testing/test_testing/MockTestRunner.py
+++ b/src/python_testing/test_testing/MockTestRunner.py
@@ -22,7 +22,13 @@
from unittest.mock import MagicMock
from chip.clusters import Attribute
-from chip.testing.matter_testing import MatterStackState, MatterTestConfig, run_tests_no_exit
+
+try:
+ from matter_testing_support import MatterStackState, MatterTestConfig, run_tests_no_exit
+except ImportError:
+ sys.path.append(os.path.abspath(
+ os.path.join(os.path.dirname(__file__), '..')))
+ from matter_testing_support import MatterStackState, MatterTestConfig, run_tests_no_exit
class AsyncMock(MagicMock):
@@ -50,15 +56,7 @@
def set_test(self, filename: str, classname: str, test: str):
self.test = test
self.config.tests = [self.test]
-
- module_name = Path(os.path.basename(filename)).stem
-
- try:
- module = importlib.import_module(module_name)
- except ModuleNotFoundError:
- sys.path.append(os.path.abspath(os.path.join(os.path.dirname(__file__), '..')))
- module = importlib.import_module(module_name)
-
+ module = importlib.import_module(Path(os.path.basename(filename)).stem)
self.test_class = getattr(module, classname)
def set_test_config(self, test_config: MatterTestConfig = MatterTestConfig()):
diff --git a/src/python_testing/test_testing/TestDecorators.py b/src/python_testing/test_testing/TestDecorators.py
index ce32518..82b49ed 100644
--- a/src/python_testing/test_testing/TestDecorators.py
+++ b/src/python_testing/test_testing/TestDecorators.py
@@ -25,13 +25,23 @@
#
# You will get step_* calls as appropriate in between the test_start and test_stop calls if the test is not skipped.
+import os
import sys
-from typing import Optional
import chip.clusters as Clusters
from chip.clusters import Attribute
-from chip.testing.matter_testing import (MatterBaseTest, MatterTestConfig, async_test_body, has_attribute, has_cluster, has_feature,
- run_if_endpoint_matches, run_on_singleton_matching_endpoint, should_run_test_on_endpoint)
+
+try:
+ from matter_testing_support import (MatterBaseTest, MatterTestConfig, async_test_body, has_attribute, has_cluster, has_feature,
+ run_if_endpoint_matches, run_on_singleton_matching_endpoint, should_run_test_on_endpoint)
+except ImportError:
+ sys.path.append(os.path.abspath(os.path.join(os.path.dirname(__file__), '..')))
+ from matter_testing_support import (MatterBaseTest, MatterTestConfig, async_test_body, has_attribute,
+ has_cluster, has_feature, run_if_endpoint_matches, run_on_singleton_matching_endpoint,
+ should_run_test_on_endpoint)
+
+from typing import Optional
+
from mobly import asserts
from MockTestRunner import MockTestRunner
diff --git a/src/python_testing/test_testing/test_IDM_10_4.py b/src/python_testing/test_testing/test_IDM_10_4.py
index 8a30609..8634e94 100644
--- a/src/python_testing/test_testing/test_IDM_10_4.py
+++ b/src/python_testing/test_testing/test_IDM_10_4.py
@@ -21,7 +21,13 @@
import chip.clusters as Clusters
from chip.clusters import Attribute
-from chip.testing.pics import parse_pics_xml
+
+try:
+ from pics_support import parse_pics_xml
+except ImportError:
+ sys.path.append(os.path.abspath(os.path.join(os.path.dirname(__file__), '..')))
+ from pics_support import parse_pics_xml
+
from MockTestRunner import MockTestRunner
# Reachable attribute is off in the pics file
diff --git a/src/python_testing/test_testing/test_TC_CCNTL_2_2.py b/src/python_testing/test_testing/test_TC_CCNTL_2_2.py
index 6a2dc48..bd28023 100644
--- a/src/python_testing/test_testing/test_TC_CCNTL_2_2.py
+++ b/src/python_testing/test_testing/test_TC_CCNTL_2_2.py
@@ -30,11 +30,11 @@
from MockTestRunner import AsyncMock, MockTestRunner
try:
- from chip.testing.matter_testing import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
+ from matter_testing_support import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
except ImportError:
sys.path.append(os.path.abspath(
os.path.join(os.path.dirname(__file__), '..')))
- from chip.testing.matter_testing import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
+ from matter_testing_support import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
invoke_call_count = 0
event_call_count = 0
diff --git a/src/python_testing/test_testing/test_TC_MCORE_FS_1_1.py b/src/python_testing/test_testing/test_TC_MCORE_FS_1_1.py
index ed9f1b3..d79b412 100644
--- a/src/python_testing/test_testing/test_TC_MCORE_FS_1_1.py
+++ b/src/python_testing/test_testing/test_TC_MCORE_FS_1_1.py
@@ -30,11 +30,11 @@
from MockTestRunner import AsyncMock, MockTestRunner
try:
- from chip.testing.matter_testing import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
+ from matter_testing_support import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
except ImportError:
sys.path.append(os.path.abspath(
os.path.join(os.path.dirname(__file__), '..')))
- from chip.testing.matter_testing import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
+ from matter_testing_support import MatterTestConfig, get_default_paa_trust_store, run_tests_no_exit
invoke_call_count = 0
event_call_count = 0
diff --git a/src/python_testing/test_testing/test_TC_SC_7_1.py b/src/python_testing/test_testing/test_TC_SC_7_1.py
index 96dced7..3b1b6a5 100644
--- a/src/python_testing/test_testing/test_TC_SC_7_1.py
+++ b/src/python_testing/test_testing/test_TC_SC_7_1.py
@@ -16,14 +16,21 @@
# limitations under the License.
#
+import os
import sys
from random import randbytes
import chip.clusters as Clusters
from chip.clusters import Attribute
-from chip.testing.matter_testing import MatterTestConfig
from MockTestRunner import MockTestRunner
+try:
+ from matter_testing_support import MatterTestConfig
+except ImportError:
+ sys.path.append(os.path.abspath(
+ os.path.join(os.path.dirname(__file__), '..')))
+ from matter_testing_support import MatterTestConfig
+
def read_trusted_root(filled: bool) -> Attribute.AsyncReadTransaction.ReadResponse:
opcreds = Clusters.OperationalCredentials
diff --git a/src/tools/PICS-generator/PICSGenerator.py b/src/tools/PICS-generator/PICSGenerator.py
index 6cfb958..acdeb67 100644
--- a/src/tools/PICS-generator/PICSGenerator.py
+++ b/src/tools/PICS-generator/PICSGenerator.py
@@ -25,10 +25,10 @@
from pics_generator_support import map_cluster_name_to_pics_xml, pics_xml_file_list_loader
from rich.console import Console
-# Add the path to python_testing folder, in order to be able to import from chip.testing.matter_testing
+# Add the path to python_testing folder, in order to be able to import from matter_testing_support
sys.path.append(os.path.abspath(sys.path[0] + "/../../python_testing"))
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main # noqa: E402
-from chip.testing.spec_parsing import build_xml_clusters # noqa: E402
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main # noqa: E402
+from spec_parsing_support import build_xml_clusters # noqa: E402
console = None
xml_clusters = None
diff --git a/src/tools/PICS-generator/XMLPICSValidator.py b/src/tools/PICS-generator/XMLPICSValidator.py
index 5fd1704..d728a61 100644
--- a/src/tools/PICS-generator/XMLPICSValidator.py
+++ b/src/tools/PICS-generator/XMLPICSValidator.py
@@ -23,7 +23,7 @@
# Add the path to python_testing folder, in order to be able to import from matter_testing_support
sys.path.append(os.path.abspath(sys.path[0] + "/../../python_testing"))
-from chip.testing.spec_parsing import build_xml_clusters # noqa: E402
+from spec_parsing_support import build_xml_clusters # noqa: E402
parser = argparse.ArgumentParser()
parser.add_argument('--pics-template', required=True)
diff --git a/src/tools/device-graph/matter-device-graph.py b/src/tools/device-graph/matter-device-graph.py
index 5974686..16a2e6d 100644
--- a/src/tools/device-graph/matter-device-graph.py
+++ b/src/tools/device-graph/matter-device-graph.py
@@ -23,9 +23,9 @@
import graphviz
from rich.console import Console
-# Add the path to python_testing folder, in order to be able to import from chip.testing.matter_testing
+# Add the path to python_testing folder, in order to be able to import from matter_testing_support
sys.path.append(os.path.abspath(sys.path[0] + "/../../python_testing"))
-from chip.testing.matter_testing import MatterBaseTest, async_test_body, default_matter_test_main # noqa: E402
+from matter_testing_support import MatterBaseTest, async_test_body, default_matter_test_main # noqa: E402
console = None
maxClusterNameLength = 30