Skip to content

docs: Add headless test instructions + reshuffle build doc format#2374

Open
cswilson252 wants to merge 2 commits intoPhotonVision:mainfrom
cswilson252:xHeadlessTests
Open

docs: Add headless test instructions + reshuffle build doc format#2374
cswilson252 wants to merge 2 commits intoPhotonVision:mainfrom
cswilson252:xHeadlessTests

Conversation

@cswilson252
Copy link
Contributor

Description

Closes #1902

What changed? Why? (the code + comments should speak for itself on the "how")

The amount of UI windows that contributors have open (and then proceed to frantically close) increases exponentially with every passing build season (Munroe 2009).

This PR adds headless (no-UI) test instructions, moves all of the test related build documentation to its own subsection (and reorders it roughly in the order we prefer they be used in), and makes the "Example" sections their own independent H2.

Meta

Merge checklist:

  • Pull Request title is short, imperative summary of proposed changes
  • The description documents the what and why, including events that led to this PR
  • If this PR changes behavior or adds a feature, user documentation is updated

@cswilson252 cswilson252 requested a review from a team as a code owner February 24, 2026 03:15
@github-actions github-actions bot added the documentation Anything relating to https://docs.photonvision.org label Feb 24, 2026
@cswilson252 cswilson252 requested a review from Gold856 February 24, 2026 05:20
```

To correctly run PhotonVision tests this way, you must [delegate the tests to Gradle](https://code.visualstudio.com/docs/java/java-build#_delegate-tests-to-gradle). Debugging tests like this will [**not** currently](https://github.com/microsoft/build-server-for-gradle/issues/119) collect outputs.
Stop any existing instance of PhotonVision.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we say how?

Stop any existing instance of PhotonVision.

### Running Tests With UI
Launch the program with the following additional argument to the JVM: {code}`java -jar -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5801 photonvision.jar`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This command says suspended, no, but the text seems to imply that suspended is enabled


## Running Tests

### Running Headless Tests
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if calling these headless is going to be confusing since everyone else does not mention this. I feel like whether or not the test is headless or not is maybe outside of the scope of the section? People care about running a particular test, and GUI Windows being hidden by default is maybe just an implementation detail

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Anything relating to https://docs.photonvision.org

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add -x test to docs for building

3 participants