fix(build): 测试文件 import 改为块形式(os/filepath/testing)

main_test.go 原为单行 import "testing",补 import 的替换锚点没命中,
导致 os/filepath 未导入、history-server 编译失败(承接上一提交的坏状态)。
本次改为块形式导入,go vet 与 go test 均通过。
This commit is contained in:
HomeDash Bot
2026-09-12 12:42:08 +08:00
parent 6c34970f38
commit b980ce6292
2 changed files with 5 additions and 2 deletions

View File

@ -424,7 +424,6 @@ func rebuildDashySections() {
}
// 收集所有导航项(排除历史访问 section 本身),带 host 访问量
hv := hostVisits()
navVisits := loadNavVisits() // 导航项点击计数:常用服务的唯一依据
type cand struct {

View File

@ -1,6 +1,10 @@
package main
import "testing"
import (
"os"
"path/filepath"
"testing"
)
func TestFriendlyHistoryTitle(t *testing.T) {
cases := []struct {