fix(ios): keep voice chat on Bluetooth headset
Build and test / test (macos-latest) (push) Waiting to run
Build and test / test (ubuntu-24.04) (push) Waiting to run
Build and test / test (windows-latest) (push) Waiting to run
Build and test / apple-client (push) Waiting to run

This commit is contained in:
2026-09-25 12:27:27 +02:00
parent f3ac779bf4
commit 724f7e912d
3 changed files with 35 additions and 6 deletions
@@ -221,6 +221,20 @@ public class PublishServerScriptTests
Assert.Contains("ReferenceEquals(engine, next) && !next.Running", engine);
}
[Fact]
public async Task IosVoiceChatLeavesBluetoothHeadsetRouteToSystem()
{
string router = await File.ReadAllTextAsync(Path.Combine(
FindRoot(), "clients", "apple", "VoiceCat.iOS", "IosAudioRouter.cs"));
Assert.Contains("if (preset == IosAudioPreset.VoiceChat) ForceSpeaker = false", router);
Assert.Contains("if (Preset == IosAudioPreset.VoiceChat) ForceSpeaker = false", router);
Assert.Contains("if (Preset == IosAudioPreset.VoiceChat) { SelectedInputId = null; SelectedDataSourceId = null; }", router);
Assert.Contains("ForceSpeaker = value; Preset = IosAudioPreset.Advanced", router);
Assert.DoesNotContain("OverrideOutputAudioPort(", router);
Assert.DoesNotContain("SelectedInputId ??= session.PreferredInput", router);
}
[Fact]
public async Task DefaultPublishTargetsWindowsAndLinuxWhileRuntimeCanSelectOne()
{