fix: allow windows handoff prerequisites in test builds

refs #3651
This commit is contained in:
Jonathan Liebig
2026-09-15 22:08:50 +02:00
committed by GitHub
parent 0ee945a44d
commit bdd9b408f8
2 changed files with 12 additions and 18 deletions
+10 -10
View File
@@ -1300,7 +1300,7 @@ impl PaneRuntimeIo {
#[cfg(windows)]
#[cfg_attr(
not(test),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
fn windows_handoff_supported(&self) -> bool {
@@ -1313,7 +1313,7 @@ impl PaneRuntimeIo {
#[cfg(windows)]
#[cfg_attr(
not(test),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
fn duplicate_windows_handoff(
@@ -1340,7 +1340,7 @@ impl PaneRuntimeIo {
#[cfg(any(unix, windows))]
#[cfg_attr(
all(windows, not(test)),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
fn begin_handoff(&self, timeout: std::time::Duration) -> std::io::Result<()> {
@@ -1353,7 +1353,7 @@ impl PaneRuntimeIo {
#[cfg(any(unix, windows))]
#[cfg_attr(
all(windows, not(test)),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
fn set_handoff_paused(&self, paused: bool) -> std::io::Result<()> {
@@ -1372,7 +1372,7 @@ impl PaneRuntimeIo {
#[cfg(any(unix, windows))]
#[cfg_attr(
all(windows, not(test)),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
fn release_after_commit(&self) -> std::io::Result<()> {
@@ -1916,7 +1916,7 @@ impl PaneRuntime {
#[cfg(windows)]
#[cfg_attr(
not(test),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
pub(crate) fn windows_handoff_supported(&self) -> bool {
@@ -1925,7 +1925,7 @@ impl PaneRuntime {
#[cfg(windows)]
#[cfg_attr(
not(test),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
pub(crate) fn duplicate_windows_handoff(
@@ -1937,7 +1937,7 @@ impl PaneRuntime {
#[cfg(any(unix, windows))]
#[cfg_attr(
all(windows, not(test)),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
pub fn preserve_for_handoff(mut self) {
@@ -1962,7 +1962,7 @@ impl PaneRuntime {
#[cfg(any(unix, windows))]
#[cfg_attr(
all(windows, not(test)),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
pub fn set_handoff_reader_paused(&self, paused: bool) {
@@ -1978,7 +1978,7 @@ impl PaneRuntime {
#[cfg(any(unix, windows))]
#[cfg_attr(
all(windows, not(test)),
windows,
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
pub fn pause_handoff_reader(&self, timeout: std::time::Duration) -> std::io::Result<()> {
+2 -8
View File
@@ -202,10 +202,7 @@ mod windows {
Release,
}
#[cfg_attr(
not(test),
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
#[allow(dead_code, reason = "used by the stacked Windows handoff integration")]
enum PtyIoControlCommand {
Resize(PtyResizeRequest),
BeginHandoff {
@@ -240,10 +237,7 @@ mod windows {
handoff_supported: bool,
}
#[cfg_attr(
not(test),
allow(dead_code, reason = "used by the stacked Windows handoff integration")
)]
#[allow(dead_code, reason = "used by the stacked Windows handoff integration")]
impl PtyIoActorHandle {
pub(crate) fn try_write_user_input(
&self,