-
Notifications
You must be signed in to change notification settings - Fork 268
Only show images during tests when requested via project property #2177
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
Only show images during tests when requested via project property #2177
Conversation
|
I'm not sure how I feel about the level of granularity here, or the implementation. It feels like a lot of complexity for little gain. I'd prefer setting and reading environment variables, at the least. |
|
Fair point to the granularity, since individual tests can also be selected. Why use environment variables over system properties? A dedicated task can be created using system properties if the granularity is removed. |
|
Environment variables are a little less bespoke in my opinion. You should still be able to have a separate test task that uses a different set of environment variables. |
|
A |
|
Did you read the StackOverflow link I sent? |
|
I meant creating a task that runs the |
|
Actually, I just realized even environment variables aren't necessary. You can just use For environment variables, I was envisioning that you just set that for the test task only, similar to how |
|
The current implementation of |
|
Yeah, I’d like to delete testHeadless and just go with the system property controlled by a project property thing I sent. We can just leave the benchmarks as they are in my opinion. |
|
The |
|
May as well just run the benchmarks. |
21d58e3 to
0f2e365
Compare
|
What I pushed now just gives the option for test UI. I found it to be fairly simple to add an option for benchmarks, so I can add that too if the CI run time is bad. |
Gold856
left a comment
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.
Beautiful.
|
Two more things actually: we should document this in the build instructions and the PR description should be updated. Then I'll merge. |
Gold856
left a comment
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.
LGTM
…otonVision#2177) ## Description Revision of PhotonVision#2164. Instead of only running headless tests during a build, now only the images are disabled. To reenable showing images, the `enableTestUi` project property needs to be passed to gradle. ```bash ./gradlew test -PenableTestUi ``` ## Meta Merge checklist: - [X] Pull Request title is [short, imperative summary](https://cbea.ms/git-commit/) of proposed changes - [X] The description documents the _what_ and _why_ - [X] This PR has been [linted](https://docs.photonvision.org/en/latest/docs/contributing/linting.html). - [x] If this PR changes behavior or adds a feature, user documentation is updated - [ ] If this PR touches photon-serde, all messages have been regenerated and hashes have not changed unexpectedly - [ ] If this PR touches configuration, this is backwards compatible with settings back to v2025.3.2 - [ ] If this PR touches pipeline settings or anything related to data exchange, the frontend typing is updated - [ ] If this PR addresses a bug, a regression test for it is added
Description
Revision of #2164. Instead of only running headless tests during a build, now only the images are disabled. To reenable showing images, the
enableTestUiproject property needs to be passed to gradle../gradlew test -PenableTestUiMeta
Merge checklist: