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

[Bug] Python test cases needs to be moved from Python Testing Suite - No commissioning to Python Testing Suite or Python Testing Suite - Old script format #506

Open
KishokG opened this issue Feb 14, 2025 · 11 comments
Assignees
Labels
bug Something isn't working python

Comments

@KishokG
Copy link

KishokG commented Feb 14, 2025

Describe the bug

Below mentioned tescases are listed under the Python Testing Suite - No commissioning in the TH UI. But this tescase needs to be commissioned before the test execution hence this testcase needs to be moved to the Python Testing Suite or Python Testing Suite - Old script format.

  • TC-DRLK-2.5
  • TC-DRLK-2.9
  • TC-MCORE-FS.1.2
  • TC-MCORE-FS.1.5
  • TC-SC-4.3
  • TC-IDM-4.2

Steps to reproduce the behavior

  1. From the Test-Harness user interface loaded the PICS file to select the test cases.
  2. Selected the python test case in Python Testing Suite - No commissioning section to executed.
  3. Click the Start button on Test-Harness user interface.

Expected behavior

The testcase needs to be commissioned before the start python test.

Log files

UI_Test_Run_2025_02_14_07_22_39.log

PICS file

Door Lock Cluster Test Plan.zip

Screenshots

Image

Environment

Version: v2.12-beta3+spring2025
Sha: 729573d

Additional Information

No response

@KishokG KishokG added the bug Something isn't working label Feb 14, 2025
@rquidute rquidute transferred this issue from project-chip/certification-tool Feb 14, 2025
@rquidute
Copy link
Contributor

For all test cases, it's just a matter of adding , is_commissioning=True so the test will be classified under Python Testing Suite suite.
I tagged some developers bellow since it seems they were involved in the listed test cases in this issue.
@vatsalghelani-csa @arkq @cecille sumaky (Can't find the right name in this repo)

@raul-marquez-csa
Copy link

@KishokG, @rquidute
This change would insert an new "step1" for commissioning in the mentioned scripts and also need a test plan update to reflect it correct?
Or is there already a test plan PR for this?

@rquidute
Copy link
Contributor

Hi @raul-marquez-csa, Can't say regarding test plan, but regarding test script, we just need to add at step 1 this information: , is_commissioning=True, see as example: https://github.com/project-chip/connectedhomeip/blob/v1.4-branch/src/python_testing/TC_BOOLCFG_2_1.py

@KishokG
Copy link
Author

KishokG commented Feb 19, 2025

@raul-marquez-csa Most of the above mentioned test cases having the commissioning step either in pre-condition or test step-1. The TC-IDM-4.2 is missing the commissioning step. But I don't think it's an big issue. We can add , is_commissioning=True variable.

@raul-marquez-csa
Copy link

Hi @raul-marquez-csa, Can't say regarding test plan, but regarding test script, we just need to add at step 1 this information: , is_commissioning=True, see as example: https://github.com/project-chip/connectedhomeip/blob/v1.4-branch/src/python_testing/TC_BOOLCFG_2_1.py

Understood, particularly what I mean is that some of those scripts don't have a step1: Commission DUT, for instance, TC_DRLK_2_5's step 1 is:

            TestStep("1", "TH reads NumberOfWeekDaySchedulesSupportedPerUser attribute.",
                     "Verify that TH is able to read the attribute successfully."),

So seems to me that we would need to change step 1 to commissioning, which makes the rest of the step numbers change, which in turn would make the test plan change to match the script.

Or maybe I'm overcomplicating things

@raul-marquez-csa
Copy link

I resolved my questions with @KishokG's help.

@raul-marquez-csa
Copy link

raul-marquez-csa commented Feb 19, 2025

PR for this issue:
Bug506 - No commissioning pre-condition or step fix #37671

  • TC-SC-4.3 had already been updated with the commissioning variable in this PR.
  • TC-IDM-4.2 also needed a test plan update as no commissioning pre-condition or commissioning step was present.
    Test Plan PR: TC-IDM-4.2 - Adds commissioning pre-condition #4969
  • Performed update to the TC-MCORE-FS-1.1 script as well

@rquidute
Copy link
Contributor

HI @raul-marquez-csa it seems there is already a PR that fixes the MCORE test cases: https://github.com/project-chip/connectedhomeip/pull/37661/files

@raul-marquez-csa
Copy link

HI @raul-marquez-csa it seems there is already a PR that fixes the MCORE test cases: https://github.com/project-chip/connectedhomeip/pull/37661/files

This is from the provided PR

TestStep(1, "Enable Fabric Synchronization on DUT_FSA using the manufacturer specified mechanism.", is_commissioning=True),

I was trying not to update as shown in the snippet in order to avoid:

  • Commissioning variable set in a step unrelated to commissioning
  • No actual explicit commissioning step in the python script
  • No commissioning print-out in the logs (command line or UI)

Please advise if I should revert my changes to those scripts or if I keep them in this PR I would also add TC_MCORE_FS_1_1.py

@rquidute
Copy link
Contributor

rquidute commented Feb 19, 2025

@raul-marquez-csa I think it makes sense the way you are doing. Looking at some test cases, it seems all test cases that contain is_commissioning=True, it is related to commissioning step at least in its description.

@raul-marquez-csa
Copy link

@raul-marquez-csa I think it makes sense the way you are doing. Looking at some test cases, it seems all test cases that contain is_commissioning=True, it is related to commissioning step at least in its description.

Ok, I'll add TC_MCORE_FS_1_1.py to this PR. The other PR should be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working python
Projects
None yet
Development

No branches or pull requests

3 participants