all: Format code with gofumpt

See https://github.com/mvdan/gofumpt
This commit is contained in:
Bjørn Erik Pedersen 2020-12-02 13:23:25 +01:00
parent 32471b57bd
commit d90e37e0c6
442 changed files with 1426 additions and 2254 deletions

View file

@ -111,7 +111,6 @@ func (ini *Init) Do() (interface{}, error) {
ini.wait()
return ini.out, ini.err
}
// TODO(bep) investigate if we can use sync.Cond for this.
@ -189,7 +188,6 @@ func (ini *Init) withTimeout(timeout time.Duration, f func(ctx context.Context)
case ve := <-c:
return ve.v, ve.err
}
}
type verr struct {

View file

@ -98,7 +98,6 @@ func TestInit(t *testing.T) {
}
_, err = branch1_2.Do()
c.Assert(err, qt.IsNil)
}(i)
wg.Wait()
@ -106,7 +105,6 @@ func TestInit(t *testing.T) {
c.Assert(result, qt.Equals, "root(1)|root(2)|branch_1|branch_1_1|branch_1_2|branch_1_2_1|")
}
}
func TestInitAddWithTimeout(t *testing.T) {
@ -142,7 +140,6 @@ func TestInitAddWithTimeoutTimeout(t *testing.T) {
c.Assert(err.Error(), qt.Contains, "timed out")
time.Sleep(1 * time.Second)
}
func TestInitAddWithTimeoutError(t *testing.T) {
@ -204,7 +201,6 @@ func TestInitBranchOrder(t *testing.T) {
// V1 is A
ab := state.V1 + "B"
state.Add2(ab)
}))
}

View file

@ -51,7 +51,6 @@ func (t *onceMore) Do(f func()) {
}
defer atomic.StoreUint32(&t.done, 1)
f()
}
func (t *onceMore) InProgress() bool {