build: Add more GitHub Actions
This commit is contained in:
+2
-1
@@ -7,6 +7,7 @@
|
||||
package meta
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"os"
|
||||
"os/exec"
|
||||
"path/filepath"
|
||||
@@ -32,7 +33,7 @@ func TestCheckGoFmt(t *testing.T) {
|
||||
cmd := exec.Command("gofmt", "-s", "-d", path)
|
||||
bs, err := cmd.CombinedOutput()
|
||||
if err != nil {
|
||||
return err
|
||||
return fmt.Errorf("%w: %s", err, string(bs))
|
||||
}
|
||||
if len(bs) != 0 {
|
||||
t.Errorf("File %s is not formatted correctly:\n\n%s", path, string(bs))
|
||||
|
||||
Reference in New Issue
Block a user