Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync csa branch with main #271

Merged
merged 39 commits into from
Feb 9, 2025
Merged
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
09833eb
Make global attributes be part of IM instead of part of DataModel::Pr…
andy31415 Feb 6, 2025
deff77a
Rename expectedResult to requiredResponse in the invokeCommands API. …
bzbarsky-apple Feb 6, 2025
9db6390
bump android docker versions (#37414)
yunhanw-google Feb 6, 2025
a998bf6
Make the build_coverage script more flexible (#37415)
yufengwangca Feb 6, 2025
d777dce
[Java] Delete finalize method in java (#37417)
joonhaengHeo Feb 6, 2025
8ec9b41
[Tizen] Fix race when storing cert credentials (#37427)
arkq Feb 6, 2025
7adac6e
Add test steps logging for TCP Tests (#37397)
pidarped Feb 6, 2025
779221f
[TC-DLOG-2.1] Updated the Manual script as per the Verification step …
Ashwinigrl Feb 6, 2025
35781e5
[PSA] bugfix for potential buffer overflow from AES_CCM Encrypt/Decry…
Alami-Amine Feb 6, 2025
2cf6dd8
[Darwin] MTRDevice should tear down subscription on dealloc (#37418)
jtung-apple Feb 6, 2025
8f28a21
Tc sc 4 1 bcm support (#36597)
simonhmorris1 Feb 6, 2025
a38f2aa
Fix condition for building test vectors (#37423)
adigie Feb 6, 2025
2a15d46
[CASESession] Follow up to refactoring Sigma Parsing functions PR (#3…
Alami-Amine Feb 6, 2025
93114c7
Auto-select data model set based on specification version (#37394)
cecille Feb 6, 2025
cbe17ed
Reduce logging in BDXTransferSession by removing logging for BlockQue…
nivi-apple Feb 7, 2025
ce47e22
Create an AAI registry for PwRPC services to allow registration of cu…
sxb427 Feb 7, 2025
e1d26a0
Fix validation of return value for invokeCommands. (#37442)
bzbarsky-apple Feb 7, 2025
2a77a11
Revert "[Java] Delete finalize method in java (#37417)" (#37446)
yunhanw-google Feb 7, 2025
ee6341e
Update chef air quality sample to use ug/m^3 (#37441)
sxb427 Feb 7, 2025
1348a8a
[Darwin] MTRDevice should throttle deviceBecameActive callbacks (#37436)
jtung-apple Feb 7, 2025
c02a091
[Tizen] Add ifdef for version-dependent Thread API (#37430)
XToripuru Feb 7, 2025
f53be4f
[Docker Image] Add zstd to chip-build (#37450)
adigie Feb 7, 2025
ff5f8fd
[Android][Docker]upgrade android sdk from 8 to 11 with java 11 suppor…
yunhanw-google Feb 7, 2025
8deebeb
telink: add instructions how to use USB logging (#37376)
BorysNykytiuk Feb 7, 2025
b536bc1
Remove stale comment from ARL example (#37321)
tleacmcsa Feb 7, 2025
ab065d2
Update TC_OCC_3_2.py to fix test step 4d failure. (#37197)
jaehs6sam Feb 7, 2025
b959364
Move OnboardingCodesUtil out of app/server (#37401)
adigie Feb 7, 2025
9799dce
Add test steps 50-60 from the Thermostat test plan to the Thermostat …
nivi-apple Feb 7, 2025
a2d94d2
Optimize flash cost for optional command in wifi diagnostic cluster (…
yufengwangca Feb 7, 2025
372345e
Don't log kNone events in BdxTransferDiagnosticLog::HandleTransferSes…
bzbarsky-apple Feb 7, 2025
333e921
Fix incorrect comment in TLVWriter. (#37459)
bzbarsky-apple Feb 7, 2025
841df09
Fix comments and naming for Darwin invoke responses validation. (#37460)
bzbarsky-apple Feb 7, 2025
b6da5d5
Updated TC-DD-1.10 YAML script with more detailed descriptions for te…
Ashwinigrl Feb 7, 2025
4c1a0c5
[ESP32] Fixed the bluedroid build issue in ESP32. (#34133)
shripad621git Feb 7, 2025
eea382e
Update TCUpdateDeadline to be nullable to match spec (#37438)
tehampson Feb 7, 2025
7a2733e
Add TCP bitflag checks to TC_SC_4_3 test. (#37347)
pidarped Feb 7, 2025
9a18149
Enable integration test during coverage statistic (#37467)
yufengwangca Feb 8, 2025
ed1babf
Convert reference to gen_config.h to the correct header file. (#37464)
harimau-qirex Feb 8, 2025
cd58e5e
Improve logging around sending XPC messages. (#37480)
bzbarsky-apple Feb 8, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/full-android.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-android:106
image: ghcr.io/project-chip/chip-build-android:108
volumes:
- "/tmp/log_output:/tmp/test_logs"

Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ jobs:
--known-failure app/util/config.h \
--known-failure app/util/DataModelHandler.cpp \
--known-failure app/util/DataModelHandler.h \
--known-failure app/util/ember-global-attribute-access-interface.h \
--known-failure app/util/ember-io-storage.h \
--known-failure app/util/endpoint-config-api.h \
--known-failure app/util/generic-callbacks.h \
Expand All @@ -133,7 +132,6 @@ jobs:
# for them. Keeping them as a list as they still need review ...
# --known-failure app/util/attribute-table.cpp \
# --known-failure app/util/ember-io-storage.cpp \
# --known-failure app/util/ember-global-attribute-access-interface.cpp \
# --known-failure app/util/attribute-storage.cpp \
- name: Check for matter lint errors
if: always()
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/smoketest-android.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-android:106
image: ghcr.io/project-chip/chip-build-android:108
volumes:
- "/:/runner-root-volume"
- "/tmp/log_output:/tmp/test_logs"
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -537,6 +537,7 @@ jobs:
scripts/run_in_python_env.sh out/venv 'python3 src/python_testing/TestIdChecks.py'
scripts/run_in_python_env.sh out/venv 'python3 src/python_testing/TestMatterTestingSupport.py'
scripts/run_in_python_env.sh out/venv 'python3 src/python_testing/TestSpecParsingDeviceType.py'
scripts/run_in_python_env.sh out/venv 'python3 src/python_testing/TestSpecParsingSelection.py'
scripts/run_in_python_env.sh out/venv 'python3 src/python_testing/TestSpecParsingSupport.py'

- name: Run Tests
Expand Down
77 changes: 62 additions & 15 deletions docs/guides/BUILDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -589,30 +589,77 @@ SDK source code has been executed. It also provides information on how often the
Matter SDK executes segments of the code and produces a copy of the source file,
annotated with execution frequencies.

Run the following command to initiate the script:
### How to Run

```
./scripts/build_coverage.sh [OPTIONS]
```

By default, the script

Builds the Matter SDK with coverage instrumentation (unless you specify a custom
--output_root). Runs the unit tests to generate coverage data. Produces an HTML
coverage report located at:

```
out/coverage/coverage/html/index.html
```

You can extend the coverage scope and test types with the following options:

Option Description -c, --code=<scope> Specify the scope to collect coverage
data. - core (default): Coverage from the core Matter SDK stack - clusters:
Coverage from cluster implementations - all: Coverage from the entire Matter SDK

--yaml Also run YAML-based tests, in addition to unit tests.

--python Also run Python-based tests, in addition to unit tests.

-o, --output_root=DIR If specified, skip the build phase and only run coverage
on the provided build output directory. This directory must have been built with
use_coverage=true and have had tests run already.

--target=<testname> When running unit tests, specifies a particular test target
to run (e.g., TestEmberAttributeBuffer.run).

-h, --help Print script usage and exit.

### Examples

Run coverage with the default scope (core) and only unit tests:

```
./scripts/build_coverage.sh
```

By default, the code coverage script is performed at the unit testing level.
Unit tests are created by developers, thus giving them the best overview of what
tests to include in unit testing. You can extend the coverage test by scope and
ways of execution with the following parameters:
Run coverage including YAML tests (plus the always-enabled unit tests):

```
./scripts/build_coverage.sh --yaml
```

Run coverage including Python tests (plus the always-enabled unit tests):

```
-c, --code Specify which scope to collect coverage data.
'core': collect coverage data from core stack in Matter SDK. --default
'clusters': collect coverage data from clusters implementation in Matter SDK.
'all': collect coverage data from Matter SDK.
-t, --tests Specify which tools to run the coverage check.
'unit': Run unit test to drive the coverage check. --default
'yaml': Run yaml test to drive the coverage check.
'all': Run unit & yaml test to drive the coverage check.
./scripts/build_coverage.sh --python
```

Also, see the up-to-date unit testing coverage report of the Matter SDK
(collected daily) at:
Run coverage including both YAML and Python tests:

```
./scripts/build_coverage.sh --yaml --python
```

Change coverage scope to all (core + clusters) and run YAML tests:

```
./scripts/build_coverage.sh --code=all --yaml
```

### Viewing Coverage Results

After the script completes, open the following file in your web browser to view
the HTML coverage report:
[matter coverage](https://matter-build-automation.ue.r.appspot.com).

## Maintaining Matter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,12 @@ class PairOnNetworkLongImReadCommand(
event.getJson().toString() == """{"0:STRUCT":{"0:UINT":1}}"""

fun checkAllAttributesJsonForFixedLabel(cluster: String): Boolean {
// TODO: this hard-codes the array and as a result it is order-dependend. This should
// be changed to be order-independent.
val expected =
"""{"65528:ARRAY-?":[],"0:ARRAY-STRUCT":[{"0:STRING":"room","1:STRING":"bedroom 2"},""" +
"""{"0:STRING":"orientation","1:STRING":"North"},{"0:STRING":"floor","1:STRING":"2"},""" +
"""{"0:STRING":"direction","1:STRING":"up"}],"65531:ARRAY-UINT":[0,65528,65529,65531,65532,65533],""" +
"""{"0:STRING":"direction","1:STRING":"up"}],"65531:ARRAY-UINT":[0,65532,65533,65528,65529,65531],""" +
""""65533:UINT":1,"65529:ARRAY-?":[],"65532:UINT":0}"""
return cluster.equals(expected)
}
Expand Down
2 changes: 1 addition & 1 deletion integrations/cloudbuild/smoke-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ steps:
- name: pwenv
path: /pwenv

- name: "ghcr.io/project-chip/chip-build-vscode:104"
- name: "ghcr.io/project-chip/chip-build-vscode:108"
id: Android
env:
- PW_ENVIRONMENT_ROOT=/pwenv
Expand Down
2 changes: 1 addition & 1 deletion integrations/docker/images/base/chip-build/version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
108 : Update vscode docker with java17 and fix java_home in java docker
109 : [Tizen] Fix race when storing cert credentials
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ def _save(self):
self.fp.seek(0)
self.fp.truncate()
pickle.dump(self.secrets, self.fp)
self.fp.flush()
except IOError as e:
print("ERROR: " + str(e), file=sys.stderr)

Expand Down Expand Up @@ -92,14 +93,14 @@ def lookup(self, label: str, **kw):
subparsers = parser.add_subparsers(dest='command', required=True)

parser_clear = subparsers.add_parser(
"clear", help="Remove passward associated with given key value pairs")
"clear", help="Remove password associated with given key value pairs")
parser_clear.add_argument("-l", "--label", action='store', required=True,
help="label for given key value pairs")
parser_clear.add_argument("kw", nargs='*',
help="key value pairs")

parser_store = subparsers.add_parser(
"store", help="Store passward for given key value pairs")
"store", help="Store password for given key value pairs")
parser_store.add_argument("-l", "--label", action='store', required=True,
help="label for given key value pairs")
parser_store.add_argument("-p", "--password", action='store', required=True,
Expand All @@ -108,7 +109,7 @@ def lookup(self, label: str, **kw):
help="key value pairs")

parser_lookup = subparsers.add_parser(
"lookup", help="Retrieve passward associated with given key value pairs")
"lookup", help="Retrieve password associated with given key value pairs")
parser_lookup.add_argument("-l", "--label", action='store', required=True,
help="label for given key value pairs")
parser_lookup.add_argument("kw", nargs='*',
Expand Down
1 change: 1 addition & 0 deletions kotlin-detect-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ style:
- "**/examples/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/clusterclient/MultiAdminClientFragment.kt"
- "**/examples/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/clusterclient/clusterinteraction/ClusterInteractionFragment.kt"
- "**/examples/android/CHIPTool/app/src/main/java/com/google/chip/chiptool/provisioning/AddressCommissioningFragment.kt"
- "**/examples/java-matter-controller/java/src/com/matter/controller/commands/pairing/PairOnNetworkLongImReadCommand.kt"
- "**/src/controller/java/src/matter/onboardingpayload/QRCodeOnboardingPayloadParser.kt"
ExplicitItLambdaParameter:
excludes:
Expand Down
Loading
Loading