]> ruderich.org/simon Gitweb - safcm/safcm.git/blobdiff - remote/sync/services_systemd_test.go
Use SPDX license identifiers
[safcm/safcm.git] / remote / sync / services_systemd_test.go
index 5aa36cd7bc38019eac8d947d374876cf05bf4f7b..7ac322c5203f56bc8ba4a744471eab739e373f6a 100644 (file)
@@ -1,17 +1,5 @@
-// Copyright (C) 2021  Simon Ruderich
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-//
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with this program.  If not, see <http://www.gnu.org/licenses/>.
+// SPDX-License-Identifier: GPL-3.0-or-later
+// Copyright (C) 2021-2024  Simon Ruderich
 
 package sync
 
@@ -61,7 +49,7 @@ LoadError=
                        },
                        [][]byte{nil},
                        []error{nil},
-                       []*exec.Cmd{&exec.Cmd{
+                       []*exec.Cmd{{
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -111,7 +99,7 @@ LoadError= ""
                        },
                        [][]byte{nil},
                        []error{nil},
-                       []*exec.Cmd{&exec.Cmd{
+                       []*exec.Cmd{{
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -161,7 +149,7 @@ LoadError=
                        },
                        [][]byte{nil},
                        []error{nil},
-                       []*exec.Cmd{&exec.Cmd{
+                       []*exec.Cmd{{
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -224,7 +212,7 @@ LoadError=
                                []byte("fake stderr"),
                        },
                        []error{nil, nil, nil, nil},
-                       []*exec.Cmd{&exec.Cmd{
+                       []*exec.Cmd{{
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -237,7 +225,7 @@ LoadError=
                                },
                                Stdout: &bytes.Buffer{},
                                Stderr: &bytes.Buffer{},
-                       }, &exec.Cmd{
+                       }, {
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -245,7 +233,7 @@ LoadError=
                                },
                                Stdout: &bytes.Buffer{},
                                Stderr: &bytes.Buffer{},
-                       }, &exec.Cmd{
+                       }, {
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -256,7 +244,7 @@ LoadError=
                                },
                                Stdout: &bytes.Buffer{},
                                Stderr: &bytes.Buffer{},
-                       }, &exec.Cmd{
+                       }, {
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -337,7 +325,7 @@ LoadError=
                        },
                        [][]byte{nil},
                        []error{nil},
-                       []*exec.Cmd{&exec.Cmd{
+                       []*exec.Cmd{{
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -423,7 +411,7 @@ LoadError=
                                nil,
                                fmt.Errorf("fake error"),
                        },
-                       []*exec.Cmd{&exec.Cmd{
+                       []*exec.Cmd{{
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -436,7 +424,7 @@ LoadError=
                                },
                                Stdout: &bytes.Buffer{},
                                Stderr: &bytes.Buffer{},
-                       }, &exec.Cmd{
+                       }, {
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",
@@ -444,7 +432,7 @@ LoadError=
                                },
                                Stdout: &bytes.Buffer{},
                                Stderr: &bytes.Buffer{},
-                       }, &exec.Cmd{
+                       }, {
                                Path: "/bin/systemctl",
                                Args: []string{
                                        "/bin/systemctl",