Cleanup: reformat all Go files
Run `go fmt` on all files, to fix their formatting. No functional changes.
This commit is contained in:
parent
b20ede97ea
commit
44ec93275d
@ -90,7 +90,7 @@ func NewCommandExecutor(cli CommandLineRunner, listener CommandListener, timeSer
|
||||
|
||||
// file-management
|
||||
"move-directory": ce.cmdMoveDirectory,
|
||||
"copy-file": ce.cmdCopyFile,
|
||||
"copy-file": ce.cmdCopyFile,
|
||||
}
|
||||
|
||||
return ce
|
||||
|
@ -215,7 +215,6 @@ func fileCopy(src, dest string) (error, string) {
|
||||
return nil, msg
|
||||
}
|
||||
|
||||
|
||||
func fileExists(filename string) bool {
|
||||
_, err := os.Stat(filename)
|
||||
return !errors.Is(err, fs.ErrNotExist)
|
||||
|
@ -345,7 +345,6 @@ func TestCmdCopyFileDestinationExists(t *testing.T) {
|
||||
assert.Error(t, f.run())
|
||||
}
|
||||
|
||||
|
||||
func TestCmdCopyFileSourceIsDir(t *testing.T) {
|
||||
f := newCmdCopyFileFixture(t)
|
||||
defer f.finish(t)
|
||||
@ -372,7 +371,6 @@ func TestCmdCopyFileSourceIsDir(t *testing.T) {
|
||||
assert.Error(t, f.run())
|
||||
}
|
||||
|
||||
|
||||
func newCmdCopyFileFixture(t *testing.T) cmdCopyFileFixture {
|
||||
mockCtrl := gomock.NewController(t)
|
||||
ce, mocks := testCommandExecutor(t, mockCtrl)
|
||||
@ -410,11 +408,11 @@ func (f cmdCopyFileFixture) finish(t *testing.T) {
|
||||
f.mockCtrl.Finish()
|
||||
}
|
||||
|
||||
func (f cmdCopyFileFixture) run() error {
|
||||
func (f cmdCopyFileFixture) run() error {
|
||||
cmd := api.Command{
|
||||
Name: "copy-file",
|
||||
Parameters: map[string]interface{}{
|
||||
"src": f.absolute_src_path,
|
||||
"src": f.absolute_src_path,
|
||||
"dest": f.absolute_dest_path,
|
||||
},
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user