style: инициализировать слайсы через make

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-08-09 00:32:47 +03:00
parent 3950dd94ee
commit 174b5f9048
7 changed files with 69 additions and 67 deletions
+11 -8
View File
@@ -74,12 +74,9 @@ func TestKeygenCmdBoth(t *testing.T) {
}
// Verify all 4 files exist.
files := []string{
prefix + ".pq.pub.pem",
prefix + ".pq.priv.pem",
prefix + ".classical.pub.pem",
prefix + ".classical.priv.pem",
}
files := make([]string, 0, 4)
files = append(files, prefix+".pq.pub.pem", prefix+".pq.priv.pem", prefix+".classical.pub.pem", prefix+".classical.priv.pem")
for _, f := range files {
if _, err := os.Stat(f); err != nil {
t.Errorf("expected file %s to exist: %v", f, err)
@@ -274,7 +271,10 @@ func TestKeygenCmdPermissions(t *testing.T) {
t.Fatalf("Execute failed: %v", err)
}
pubFiles := []string{prefix + ".pq.pub.pem", prefix + ".classical.pub.pem"}
pubFiles := make([]string, 0, 2)
pubFiles = append(pubFiles, prefix+".pq.pub.pem", prefix+".classical.pub.pem")
for _, f := range pubFiles {
info, err := os.Stat(f)
if err != nil {
@@ -286,7 +286,10 @@ func TestKeygenCmdPermissions(t *testing.T) {
}
}
privFiles := []string{prefix + ".pq.priv.pem", prefix + ".classical.priv.pem"}
privFiles := make([]string, 0, 2)
privFiles = append(privFiles, prefix+".pq.priv.pem", prefix+".classical.priv.pem")
for _, f := range privFiles {
info, err := os.Stat(f)
if err != nil {