diff options
author | Abhinav Gupta <mail@abhinavg.net> | 2021-11-27 14:26:38 -0800 |
---|---|---|
committer | Abhinav Gupta <mail@abhinavg.net> | 2021-11-27 16:39:09 -0800 |
commit | 07a8bcc71afb5814c00c7a7b19c29b0c493a18fd (patch) | |
tree | e57ec50bc3e51cea46fc589c4a3cd0586869a2aa /worktree_commit_test.go | |
parent | e4fcd078d42e945581616855ab78d8b7ed12df6c (diff) | |
download | go-git-07a8bcc71afb5814c00c7a7b19c29b0c493a18fd.tar.gz |
Remove unused variables/types/functions
[staticcheck](https://staticcheck.io/) reported a number of unused
fields, functions, types, and variables across the code.
Where possible, use them (assert unchecked errors in tests, for example)
and otherwise remove them.
Diffstat (limited to 'worktree_commit_test.go')
-rw-r--r-- | worktree_commit_test.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/worktree_commit_test.go b/worktree_commit_test.go index 65d4b69..097c6e5 100644 --- a/worktree_commit_test.go +++ b/worktree_commit_test.go @@ -212,10 +212,10 @@ func (s *WorktreeSuite) TestCommitTreeSort(c *C) { defer clean() st := filesystem.NewStorage(fs, cache.NewObjectLRUDefault()) - r, err := Init(st, nil) + _, err := Init(st, nil) c.Assert(err, IsNil) - r, _ = Clone(memory.NewStorage(), memfs.New(), &CloneOptions{ + r, _ := Clone(memory.NewStorage(), memfs.New(), &CloneOptions{ URL: fs.Root(), }) @@ -296,6 +296,7 @@ func (s *WorktreeSuite) TestJustStoreObjectsNotAlreadyStored(c *C) { All: true, Author: defaultSignature(), }) + c.Assert(err, IsNil) c.Assert(hash, Equals, plumbing.NewHash("97c0c5177e6ac57d10e8ea0017f2d39b91e2b364")) // Step 3: Check |