-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Tests yaml #6944
Tests yaml #6944
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @vivien-apple. Agree with @andy31415 's feedback, and is this PR planning to have C++ chip-tool included as well? How about python?
8efc8d9
to
6fb29ce
Compare
I have added chip-tool C++ generation as well. So the same test description is generating tests for the Darwin CI, as well as tests for Under
Those tests can then be runned by adding the test name at the end, e.g For python support it sounds like the way to add them will be update |
Thanks @vivien-apple ! |
@vivien-apple - since this does code generation, will we need to check-in more generated code or is this for manual runs only (and generate manually as needed)? I would find checking in test sequences/yaml code useful however historically checking in generated code from zap causes very large PRs that tend to hide real code changes between auto-generated code, making them hard to review. What is the expected flow when using yaml test cases? Can we have a model where we have only yaml files and check in generated files? |
Do we need zap or if we rely only on yaml files could we generate in pure python (easier to integrate in the build system if pure python)? Could we convert the tests to generic POSIX? We have many developers who only have a linux machine and github charges 10x minutes when using darwin instead of linux backends. |
The plan is to convert these to POSIX as soon as possible, though I think we should get this in... this will help substantially test the C++ api here. |
Put up this to bring it into CI: |
* Add a simple helper for ZAP templates in order to generate tests from YAML files * Update gen/ folder
Problem
In order to make it easier to create Cluster tests that may exercise the different high level layers of the controller, this PR introduce some tests written in
yaml
to make them easier to read and understand.Those are basic tests, one for the
Test Cluster
in order support adding exotic commands to it and see if they work, the other is some test against theOnOff Cluster
in order to validate that sending commands update the attribute appropriately.Summary of Changes
TestHelper.js
in order to get ZAP to understand those YAML templatesonoff.yaml
andtest.yaml
into a new foldersrc/app/tests/yaml/
Darwin CI
task