style(frontend): gofmt the apiserver and xcecli sources

Formatting only (gofmt -w on the 29 non-vendored, non-generated files
gofmt -l reported); swag-generated apiserver/docs/docs.go left as is.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Rongsong Shen 2026-10-02 09:33:16 +00:00
parent b57ce6d6a9
commit 3615c7c0fb
Signed by untrusted user: rshen
GPG key ID: 80533536B0EB651C
29 changed files with 1280 additions and 1285 deletions

View file

@ -675,4 +675,4 @@ func TestIntegration_SpecialCharactersInHostname(t *testing.T) {
if hostnameVal != xssHostname {
t.Errorf("hostname round-trip: got %q, want %q", hostnameVal, xssHostname)
}
}
}

View file

@ -27,7 +27,7 @@ import (
const (
//TODO: Need assign clusterID globally.
clusterID = 1
clusterID = 1
apiserverID = 0
)
@ -3190,4 +3190,3 @@ func GetHostList(hosts []string) ([]string, error) {
}
return execHosts, nil
}

View file

@ -1,11 +1,11 @@
package controllers
import (
"errors"
"apiserver/backend"
"apiserver/models"
"apiserver/store"
"apiserver/utils"
"errors"
"strings"
"testing"

View file

@ -242,4 +242,3 @@ func parseJobIDParam(jobidStr string) (models.JobInfo, error) {
ArrayIdx: 0, // peek defaults to base job; array idx can be added later
}, nil
}

View file

@ -237,7 +237,7 @@ func TestGetJobOutput_DefaultPathFallback(t *testing.T) {
// Use a real-ish packed job ID: cluster=1, apiserver=0, ts=1778311965, seq=0
// FormatJobID → "1-0-1778311965-0"
// WorkerDefaultOutputPath → "/tmp/job_1-0-1778311965-0_task0.out"
const uniqueID = int64(0x0100000006A04BDD<<0) // MakeJobID(1,0,1778311965,0,0)
const uniqueID = int64(0x0100000006A04BDD << 0) // MakeJobID(1,0,1778311965,0,0)
// Use backend.MakeJobID directly for clarity; compute inline:
// clusterID=1 at bit 56, timestamp=1778311965 at bit 20
// packed = (1 << 56) | (1778311965 << 20)
@ -512,4 +512,3 @@ func TestGetJobOutput_DoneJob(t *testing.T) {
t.Errorf("job_status = %q, want DONE", resp.Data.JobStatus)
}
}