-
Notifications
You must be signed in to change notification settings - Fork 2
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: on_target: add pkk test #96
Conversation
PPK test with readme badge and html plot. Signed-off-by: Giacomo Dematteis <giacomo.dematteis@nordicsemi.no>
fd98d62
to
5dde2a5
Compare
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.
🎯 Core Changes
- The main purpose of this PR is to introduce a new PPK (Power Profiler Kit) test for the asset-tracker-template project. This includes adding a new test script
test_power.py
which measures power consumption and generates reports in CSV and HTML formats. - The GitHub Actions workflows have been updated to include the new PPK test. The
target-test.yml
workflow now supports running tests on multiple devices, including a new deviceppk_thingy91x
which only runs when the 'slow' marker is specified. - Permissions for the
test
job inbuild-and-target-test.yml
andtarget-test.yml
have been modified to allow writing to contents.
- The change in permissions from
contents: read
tocontents: write
in the GitHub Actions workflows could potentially allow unintended modifications to the repository contents if not properly secured.
- Verdict:
- Comment: The changes introduce a useful new test and enhance the CI/CD workflows, but the modification of permissions to allow writing to contents should be reviewed to ensure it does not introduce security risks.
Code review performed by OPENAI - gpt-4o
.
@@ -22,7 +22,7 @@ jobs: | |||
test: | |||
permissions: | |||
actions: read | |||
contents: read | |||
contents: write |
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.
Changing permissions from contents: read
to contents: write
can introduce security risks if not properly managed. Ensure that the workflow is secure and that only trusted code can execute with these permissions.
|
||
# Self-hosted runner is labeled according to the device it is linked with | ||
runs-on: ${{ matrix.device }} | ||
name: Target Test - ${{ matrix.device }} | ||
|
||
permissions: | ||
actions: read | ||
contents: read | ||
contents: write |
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.
Similar to the build-and-target-test.yml
, changing permissions from contents: read
to contents: write
requires careful consideration. Verify that this change is necessary and that appropriate security measures are in place.
PPK test with readme badge and html plot.