mirror of
https://github.com/opencontainers/runc.git
synced 2026-07-11 06:03:57 +08:00
Use gofumpt to format code
gofumpt (mvdan.cc/gofumpt) is a fork of gofmt with stricter rules. Brought to you by git ls-files \*.go | grep -v ^vendor/ | xargs gofumpt -s -w Looking at the diff, all these changes make sense. Also, replace gofmt with gofumpt in golangci.yml. Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
This commit is contained in:
@@ -44,12 +44,18 @@ func TestCpuacctStats(t *testing.T) {
|
||||
|
||||
expectedStats := cgroups.CpuUsage{
|
||||
TotalUsage: uint64(12262454190222160),
|
||||
PercpuUsage: []uint64{1564936537989058, 1583937096487821, 1604195415465681, 1596445226820187,
|
||||
1481069084155629, 1478735613864327, 1477610593414743, 1476362015778086},
|
||||
PercpuUsageInKernelmode: []uint64{637727786389114, 638197595421064, 638956774598358, 637985531181620,
|
||||
638837766495476, 638763309884944, 640081778921247, 638716766259495},
|
||||
PercpuUsageInUsermode: []uint64{962250696038415, 981956408513304, 1002658817529022, 994937703492523,
|
||||
874843781648690, 872544369885276, 870104915696359, 870202363887496},
|
||||
PercpuUsage: []uint64{
|
||||
1564936537989058, 1583937096487821, 1604195415465681, 1596445226820187,
|
||||
1481069084155629, 1478735613864327, 1477610593414743, 1476362015778086,
|
||||
},
|
||||
PercpuUsageInKernelmode: []uint64{
|
||||
637727786389114, 638197595421064, 638956774598358, 637985531181620,
|
||||
638837766495476, 638763309884944, 640081778921247, 638716766259495,
|
||||
},
|
||||
PercpuUsageInUsermode: []uint64{
|
||||
962250696038415, 981956408513304, 1002658817529022, 994937703492523,
|
||||
874843781648690, 872544369885276, 870104915696359, 870202363887496,
|
||||
},
|
||||
UsageInKernelmode: (uint64(291429664) * nanosecondsInSecond) / clockTicks,
|
||||
UsageInUsermode: (uint64(452278264) * nanosecondsInSecond) / clockTicks,
|
||||
}
|
||||
@@ -78,8 +84,10 @@ func TestCpuacctStatsWithoutUsageAll(t *testing.T) {
|
||||
|
||||
expectedStats := cgroups.CpuUsage{
|
||||
TotalUsage: uint64(12262454190222160),
|
||||
PercpuUsage: []uint64{1564936537989058, 1583937096487821, 1604195415465681, 1596445226820187,
|
||||
1481069084155629, 1478735613864327, 1477610593414743, 1476362015778086},
|
||||
PercpuUsage: []uint64{
|
||||
1564936537989058, 1583937096487821, 1604195415465681, 1596445226820187,
|
||||
1481069084155629, 1478735613864327, 1477610593414743, 1476362015778086,
|
||||
},
|
||||
PercpuUsageInKernelmode: []uint64{},
|
||||
PercpuUsageInUsermode: []uint64{},
|
||||
UsageInKernelmode: (uint64(291429664) * nanosecondsInSecond) / clockTicks,
|
||||
|
||||
Reference in New Issue
Block a user