Ariver
2026-07-11 015f1089ea875a153dd2a18ef42c25145d4868f5
C1.source/privatevoice.src/internal/config/config_test.go
@@ -25,22 +25,25 @@
   if cfg.ModelSelectionMode != ModelSelectionModeAuto {
      t.Fatalf("model selection mode = %q, want %q", cfg.ModelSelectionMode, ModelSelectionModeAuto)
   }
   if cfg.AutoPasteExperiment {
      t.Fatal("AutoPasteExperiment default = true, want false")
   }
}
func TestDefaultHotkeyForNewConfig(t *testing.T) {
   tests := []struct {
      goos string
      want int
   }{
      {goos: "darwin", want: RightModifierDefaultVK},
      {goos: "windows", want: RightModifierDefaultVK},
      {goos: "linux", want: LegacyDefaultHotkeyVK},
   if got := defaultHotkeyVKForNewConfig("darwin"); defaultHotkeyUnsetForNewConfig("darwin") {
      if got != UnsetHotkeyVK {
         t.Fatalf("darwin appstore default = 0x%X, want unset", got)
      }
   } else if got != RightModifierDefaultVK {
      t.Fatalf("darwin default = 0x%X, want 0x%X", got, RightModifierDefaultVK)
   }
   for _, tt := range tests {
      if got := defaultHotkeyVKForNewConfig(tt.goos); got != tt.want {
         t.Fatalf("defaultHotkeyVKForNewConfig(%q) = 0x%X, want 0x%X", tt.goos, got, tt.want)
      }
   if got := defaultHotkeyVKForNewConfig("windows"); got != RightModifierDefaultVK {
      t.Fatalf("windows default = 0x%X, want 0x%X", got, RightModifierDefaultVK)
   }
   if got := defaultHotkeyVKForNewConfig("linux"); got != LegacyDefaultHotkeyVK {
      t.Fatalf("linux default = 0x%X, want 0x%X", got, LegacyDefaultHotkeyVK)
   }
}