blob: 84bf41cfbafacd175597b77c26b9525e8f4c6e03 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
env GO111MODULE=off
! go fmt does-not-exist
go fmt -n exclude
stdout 'exclude[/\\]x\.go'
stdout 'exclude[/\\]x_linux\.go'
# Test edge cases with gofmt.
# Note that this execs GOROOT/bin/gofmt.
! exec gofmt does-not-exist
exec gofmt gofmt-dir/no-extension
stdout 'package x'
exec gofmt gofmt-dir
! stdout 'package x'
-- exclude/empty/x.txt --
-- exclude/ignore/_x.go --
package x
-- exclude/x.go --
// +build linux,!linux
package x
-- exclude/x_linux.go --
// +build windows
package x
-- gofmt-dir/no-extension --
package x
|