Files
beardrive/cmd/bdrive/autostart_help_test.go
T
Snow Lee (Sungwon)andGitHub 7dd5d097fe docs: one answer on Windows support — macOS and Linux only (BEA-77) (#126)
"Can my Windows teammate join?" got three answers from three official
surfaces: README's feature list said macOS & Linux, its CLI table
documented an HKCU Run entry on Windows, and the hub's Installation page
named no OS at all.

Windows autostart is real code that cannot run — internal/store's flock
and internal/daemon's Kill/Setsid are unix-only, so GOOS=windows does
not build. The fix is the docs, not the port: every Windows claim comes
out of README, web/docs and `bdrive autostart`'s own help, and the
Installation page gains one line naming the supported systems.

No Go source is deleted; internal/autostart/autostart_windows.go stays
compiled-but-dormant for whenever the port happens.
2026-08-11 00:52:46 +09:00

28 lines
672 B
Go

package main
import (
"strings"
"testing"
"github.com/spf13/cobra"
)
// Windows autostart code exists but cannot run — internal/store and
// internal/daemon do not build for Windows — so no help text may promise it.
// BEA-77: three surfaces gave three different answers to "can my Windows
// teammate join?".
func TestAutostartHelpNamesNoWindows(t *testing.T) {
var walk func(*cobra.Command)
walk = func(c *cobra.Command) {
for _, s := range []string{c.Short, c.Long} {
if strings.Contains(s, "Windows") {
t.Errorf("%q help mentions Windows: %s", c.Name(), s)
}
}
for _, sub := range c.Commands() {
walk(sub)
}
}
walk(autostartCmd())
}