Repository navigation
docs(governance): add cross-harness orchestration governance proposal #144
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
Changes from all commits
b9b4f86
4b41081
6567919
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -24,26 +24,32 @@ fn launches_after_third_do_not_show_generic_alignment_tip() { | |
| assert!(startup_hints_for_launch(&state).is_none()); | ||
| } | ||
|
|
||
| // Asserts the macOS-specific spawn notice text (`Cmd+;` etc.), so it only makes | ||
| // sense on macOS. On other platforms the notice uses different chords/wording. | ||
| // The macOS launch-hotkey spawn notice was retired by PR #128 (commit | ||
| // 081c1cf6, "refactor(setup-hints): remove unreachable startup spawn notice"): | ||
| // nothing in the crate ever wrote `startup_spawn_hint_dismissed = false`, so | ||
| // the prior `if !hotkey_configured || dismissed` gate always evaluated to None | ||
| // in practice. The function now returns `None` unconditionally. This test | ||
| // stays as a regression guard against the gate being re-introduced with the | ||
| // wrong default, and to keep the macOS-only cfg symmetric with the other | ||
| // launch-hotkey notice tests in this file. | ||
| #[cfg(target_os = "macos")] | ||
| #[test] | ||
| fn first_three_launches_can_include_hotkey_notice_too() { | ||
| let state = SetupHintsState { | ||
| launch_count: 2, | ||
| hotkey_configured: true, | ||
| // Even when the user has dismissed the (now-retired) notice, the | ||
| // function must still return None — the spawn notice was retired, | ||
| // not gated. Re-introducing a hotkey-notice gate here would require | ||
| // also fixing this assertion. | ||
| startup_spawn_hint_dismissed: true, | ||
| ..SetupHintsState::default() | ||
| }; | ||
|
|
||
| let hints = startup_hints_for_launch(&state).expect("expected startup hint"); | ||
| let (_, message) = hints.display_message.expect("expected display message"); | ||
| assert!(!message.contains("Alt+C")); | ||
| assert!(message.contains("Cmd+;")); | ||
| // The notice should make clear the hotkey works globally, not just inside jcode. | ||
| assert!(message.contains("system-wide")); | ||
| // All three launch hotkeys should be mentioned. | ||
| assert!(message.contains("Cmd+'")); | ||
| assert!(message.contains("Cmd+Shift+'")); | ||
| assert!( | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. WARNING: The assertion is vacuous —
This is broader than the CodeAnt nitpick on line 45: flipping Two options:
As written, the test can never fail and will silently stop guarding anything if the function is ever rewritten. |
||
| startup_hints_for_launch(&state).is_none(), | ||
| "spawn notice was retired in PR #128; startup_hints_for_launch must always return None", | ||
| ); | ||
| } | ||
|
|
||
| #[test] | ||
|
|
||
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.
WARNING: The macOS-only
cfggate is now vestigial, and the test name contradicts the assertionCmd+;,Cmd+Shift+). Now the#[cfg(target_os = "macos")]gate compiles this regression guard out entirely on Linux CI, i.e. it provides no coverage in the default CI environment. Drop thecfgso the guard runs everywhere.first_three_launches_can_include_hotkey_notice_toonow states the opposite of what the test asserts (can include a hotkey noticevsmust always return None). Anyone grepping for the hotkey-notice tests will be misled — rename it to describe the retired behaviour, e.g.startup_spawn_notice_is_always_retired.