cli/command: fix formatting of comments, and minor linting issues

Comments should have a leading space unless the comment is
for special purposes (go:generate, nolint:)

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2020-01-16 12:47:12 +01:00
parent 6e5528b650
commit 73dcf50d5a
No known key found for this signature in database
GPG Key ID: 76698F39D527CE8C
4 changed files with 6 additions and 8 deletions

View File

@ -40,11 +40,9 @@ func testDefaultMetadata() store.Metadata {
} }
func testStore(t *testing.T, meta store.Metadata, tls store.ContextTLSData) (store.Store, func()) { func testStore(t *testing.T, meta store.Metadata, tls store.ContextTLSData) (store.Store, func()) {
//meta := testDefaultMetadata()
testDir, err := ioutil.TempDir("", t.Name()) testDir, err := ioutil.TempDir("", t.Name())
assert.NilError(t, err) assert.NilError(t, err)
//defer os.RemoveAll(testDir) s := &ContextStoreWithDefault{
store := &ContextStoreWithDefault{
Store: store.New(testDir, testCfg), Store: store.New(testDir, testCfg),
Resolver: func() (*DefaultContext, error) { Resolver: func() (*DefaultContext, error) {
return &DefaultContext{ return &DefaultContext{
@ -53,8 +51,8 @@ func testStore(t *testing.T, meta store.Metadata, tls store.ContextTLSData) (sto
}, nil }, nil
}, },
} }
return store, func() { return s, func() {
os.RemoveAll(testDir) _ = os.RemoveAll(testDir)
} }
} }