dankbar: trace goth wings and adjacent-bar seams in the border outline

fixes #3502
This commit is contained in:
bbedward committed 2026-09-21 22:14:42 -04:00
1 parent 8538b303e3
commit e9498716f9
2 files changed
+30 -1

No files matched your search

+4 -1
View File
@@ -140,8 +140,11 @@ exit "$dms_update_status"`
var argv []string
execFlag := "-e"
switch term {
case "kitty", "alacritty", "wezterm":
case "kitty", "alacritty":
argv = []string{term, "--class", appID, "-T", title}
case "wezterm":
argv = []string{term, "start", "--always-new-process", "--class", appID}
execFlag = "--"
case "foot":
argv = []string{term, "--app-id=" + appID, "--title=" + title}
case "ghostty":
@@ -4,10 +4,36 @@ import (
"errors"
"os"
"os/exec"
"slices"
"strings"
"testing"
)
func TestTerminalWrapperWezterm(t *testing.T) {
for _, tt := range []struct {
name string
extraArgs []string
want []string
}{
{
name: "update",
want: []string{"wezterm", "start", "--always-new-process", "--class", "com.danklinux.dms", "--", "sh", "-c"},
},
{
name: "extra arguments",
extraArgs: []string{"--cwd", "/tmp/system update"},
want: []string{"wezterm", "start", "--always-new-process", "--class", "com.danklinux.dms", "--cwd", "/tmp/system update", "--", "sh", "-c"},
},
} {
t.Run(tt.name, func(t *testing.T) {
argv := wrapInTerminal("wezterm", "Test", "true", tt.extraArgs)
if len(argv) != len(tt.want)+1 || !slices.Equal(argv[:len(argv)-1], tt.want) {
t.Fatalf("argv = %q, want %q followed by the update script", argv, tt.want)
}
})
}
}
func TestTerminalWrapperPreservesExitStatus(t *testing.T) {
for _, tt := range []struct {
command string