From e4947a73088c06148a98aeef02d48bad0d760bd5 Mon Sep 17 00:00:00 2001 From: Vivien Nicolas Date: Tue, 31 Jan 2023 15:57:26 +0100 Subject: [PATCH] Fix typos in src/app/tests/suites/certifications/[Test_TC_MEDIAPLAYBACK_6_*|Test_TC_ACE_1_1].yaml (#24750) * Fix typos in src/app/tests/suites/certifications/[Test_TC_MEDIAPLAYBACK_6_*|Test_TC_ACE_1_1].yaml * Update generated tests content --- .../suites/certification/Test_TC_ACE_1_1.yaml | 2 +- .../Test_TC_MEDIAPLAYBACK_6_1.yaml | 8 +++---- .../Test_TC_MEDIAPLAYBACK_6_2.yaml | 22 +++++++++---------- .../Test_TC_MEDIAPLAYBACK_6_3.yaml | 8 +++---- .../Test_TC_MEDIAPLAYBACK_6_4.yaml | 12 +++++----- .../chip-tool/zap-generated/test/Commands.h | 8 +++++++ .../zap-generated/test/Commands.h | 14 ++++++++++++ 7 files changed, 48 insertions(+), 26 deletions(-) diff --git a/src/app/tests/suites/certification/Test_TC_ACE_1_1.yaml b/src/app/tests/suites/certification/Test_TC_ACE_1_1.yaml index 37a79d5a34534b..76236844056a67 100644 --- a/src/app/tests/suites/certification/Test_TC_ACE_1_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_ACE_1_1.yaml @@ -53,7 +53,7 @@ tests: cluster: "Operational Credentials" command: "readAttribute" attribute: "NOCs" - returns: + response: constraints: minLength: 1 maxLength: 1 diff --git a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_1.yaml b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_1.yaml index 43c06224dd237d..d8f15a1db703ce 100644 --- a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_1.yaml @@ -38,7 +38,7 @@ tests: PICS: MEDIAPLAYBACK.S.C01.Rsp response: values: - - name: "status" + - name: "Status" value: 0 - label: "Reads the CurrentState attribute" @@ -53,7 +53,7 @@ tests: command: "Play" response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the media state is playing" @@ -79,7 +79,7 @@ tests: command: "Pause" response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the media is paused" @@ -105,7 +105,7 @@ tests: command: "Stop" response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the media is stoped" diff --git a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_2.yaml b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_2.yaml index 2243b7a6a1fcdf..846a719718186f 100644 --- a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_2.yaml +++ b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_2.yaml @@ -38,7 +38,7 @@ tests: PICS: MEDIAPLAYBACK.S.C01.Rsp response: values: - - name: "status" + - name: "Status" value: 0 - label: "Reads the CurrentState attribute from the DUT" @@ -53,7 +53,7 @@ tests: command: "Play" response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the media state is playing" @@ -79,7 +79,7 @@ tests: command: "StartOver" response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the media is started over" @@ -98,7 +98,7 @@ tests: command: "Next" response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the next media item in the queue has been loaded" @@ -118,7 +118,7 @@ tests: command: "Previous" response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the previous media item in the queue has been loaded" @@ -139,11 +139,11 @@ tests: command: "SkipForward" arguments: values: - - name: "deltaPositionMilliseconds" + - name: "DeltaPositionMilliseconds" value: 10000 response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the media has skipped forward 10 seconds" @@ -163,18 +163,18 @@ tests: command: "readAttribute" attribute: "SampledPosition" response: - value: 10000 + value: { "Position": 10000 } - label: "Sends a SkipBackward command to the DUT " PICS: MEDIAPLAYBACK.S.C09.Rsp command: "SkipBackward" arguments: values: - - name: "deltaPositionMilliseconds" + - name: "DeltaPositionMilliseconds" value: 10000 response: values: - - name: "status" + - name: "Status" value: 0 - label: "Verify that the media has skipped backward 10 seconds" @@ -194,4 +194,4 @@ tests: command: "readAttribute" attribute: "SampledPosition" response: - value: 0 + value: { "Position": 0 } diff --git a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_3.yaml b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_3.yaml index 6969b4fc0aed8e..7b6a8d7f04adb9 100644 --- a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_3.yaml +++ b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_3.yaml @@ -41,7 +41,7 @@ tests: PICS: MEDIAPLAYBACK.S.C01.Rsp response: values: - - name: "status" + - name: "Status" value: 0 - label: "Sends a Seek command" @@ -53,7 +53,7 @@ tests: value: 10000 response: values: - - name: "status" + - name: "Status" value: 0 - label: @@ -75,7 +75,7 @@ tests: command: "readAttribute" attribute: "SampledPosition" response: - value: 10000 + value: { "Position": 10000 } #Issue 10988 - label: "TH reads the StartTime attribute from the DUT" @@ -173,7 +173,7 @@ tests: value: SeekPosition response: values: - - name: "status" + - name: "Status" value: 5 - label: "verify that the media has not moved." diff --git a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_4.yaml b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_4.yaml index d6c24703932310..17ba4d8cbb7334 100644 --- a/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_4.yaml +++ b/src/app/tests/suites/certification/Test_TC_MEDIAPLAYBACK_6_4.yaml @@ -38,7 +38,7 @@ tests: PICS: MEDIAPLAYBACK.S.C01.Rsp response: values: - - name: "status" + - name: "Status" value: 0 - label: "Reads the CurrentState attribute from the DUT" @@ -60,7 +60,7 @@ tests: command: "FastForward" response: values: - - name: "status" + - name: "Status" value: 0 - label: "verify that the media state is playing" @@ -93,7 +93,7 @@ tests: command: "FastForward" response: values: - - name: "status" + - name: "Status" value: 0 - label: "verify that the media play speed has increased." @@ -119,7 +119,7 @@ tests: command: "Rewind" response: values: - - name: "status" + - name: "Status" value: 0 - label: "verify that the media play has reversed direction." @@ -162,7 +162,7 @@ tests: command: "Rewind" response: values: - - name: "status" + - name: "Status" value: 0 - label: @@ -202,7 +202,7 @@ tests: command: "Play" response: values: - - name: "status" + - name: "Status" value: 0 - label: diff --git a/zzz_generated/chip-tool/zap-generated/test/Commands.h b/zzz_generated/chip-tool/zap-generated/test/Commands.h index b5b830bdfc252f..7b06be89ef5f12 100644 --- a/zzz_generated/chip-tool/zap-generated/test/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/test/Commands.h @@ -7431,6 +7431,8 @@ class Test_TC_ACE_1_1Suite : public TestCommand chip::app::DataModel::DecodableList value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintMinLength("value", value, 1)); + VerifyOrReturn(CheckConstraintMaxLength("value", value, 1)); } break; case 3: @@ -35295,6 +35297,8 @@ class Test_TC_MEDIAPLAYBACK_6_2Suite : public TestCommand value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); VerifyOrReturn(CheckValueNonNull("sampledPosition", value)); + VerifyOrReturn(CheckValueNonNull("sampledPosition.Value().position", value.Value().position)); + VerifyOrReturn(CheckValue("sampledPosition.Value().position.Value()", value.Value().position.Value(), 10000ULL)); } break; case 15: @@ -35316,6 +35320,8 @@ class Test_TC_MEDIAPLAYBACK_6_2Suite : public TestCommand value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); VerifyOrReturn(CheckValueNonNull("sampledPosition", value)); + VerifyOrReturn(CheckValueNonNull("sampledPosition.Value().position", value.Value().position)); + VerifyOrReturn(CheckValue("sampledPosition.Value().position.Value()", value.Value().position.Value(), 0ULL)); } break; default: @@ -35595,6 +35601,8 @@ class Test_TC_MEDIAPLAYBACK_6_3Suite : public TestCommand value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); VerifyOrReturn(CheckValueNonNull("sampledPosition", value)); + VerifyOrReturn(CheckValueNonNull("sampledPosition.Value().position", value.Value().position)); + VerifyOrReturn(CheckValue("sampledPosition.Value().position.Value()", value.Value().position.Value(), 10000ULL)); } break; case 5: diff --git a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h index 39b5ddbbd8c4b3..aacdf5da47674e 100644 --- a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h +++ b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h @@ -4632,6 +4632,8 @@ class Test_TC_ACE_1_1 : public TestCommandBridge { VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + VerifyOrReturn(CheckConstraintMinLength("NOCs", value, 1)); + VerifyOrReturn(CheckConstraintMaxLength("NOCs", value, 1)); NextTest(); }]; @@ -46866,6 +46868,10 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { { id actualValue = value; VerifyOrReturn(CheckValueNonNull("SampledPosition", actualValue)); + VerifyOrReturn( + CheckValueNonNull("Position", ((MTRMediaPlaybackClusterPlaybackPositionStruct *) actualValue).position)); + VerifyOrReturn( + CheckValue("Position", ((MTRMediaPlaybackClusterPlaybackPositionStruct *) actualValue).position, 10000ULL)); } NextTest(); @@ -46930,6 +46936,10 @@ class Test_TC_MEDIAPLAYBACK_6_2 : public TestCommandBridge { { id actualValue = value; VerifyOrReturn(CheckValueNonNull("SampledPosition", actualValue)); + VerifyOrReturn( + CheckValueNonNull("Position", ((MTRMediaPlaybackClusterPlaybackPositionStruct *) actualValue).position)); + VerifyOrReturn( + CheckValue("Position", ((MTRMediaPlaybackClusterPlaybackPositionStruct *) actualValue).position, 0ULL)); } NextTest(); @@ -47224,6 +47234,10 @@ class Test_TC_MEDIAPLAYBACK_6_3 : public TestCommandBridge { { id actualValue = value; VerifyOrReturn(CheckValueNonNull("SampledPosition", actualValue)); + VerifyOrReturn( + CheckValueNonNull("Position", ((MTRMediaPlaybackClusterPlaybackPositionStruct *) actualValue).position)); + VerifyOrReturn( + CheckValue("Position", ((MTRMediaPlaybackClusterPlaybackPositionStruct *) actualValue).position, 10000ULL)); } NextTest();