summaryrefslogtreecommitdiff
path: root/tests/matrix
diff options
context:
space:
mode:
authorJakob Unterwurzacher2021-08-19 08:31:53 +0200
committerJakob Unterwurzacher2021-08-19 08:34:49 +0200
commitbe2bd4eec7de3836da56a3532ecbcf45a127ece2 (patch)
treeba918035cb074ea1e4ee6fd0ec712f5ea28c5097 /tests/matrix
parentd8b8232c3c4fa309e11567f6fb42c9642dd9d24c (diff)
golangci-lint: fix issues found by "unused" and "deadcode"
Except xattrSupported, this is a false positive. $ golangci-lint run --disable-all --enable unused --enable deadcode gocryptfs-xray/xray_main.go:24:5: `GitVersionFuse` is unused (deadcode) var GitVersionFuse = "[GitVersionFuse not set - please compile using ./build.bash]" ^ tests/symlink_race/main.go:47:6: `chmodLoop` is unused (deadcode) func chmodLoop() { ^ internal/readpassword/extpass_test.go:11:5: `testPw` is unused (deadcode) var testPw = []byte("test") ^ tests/reverse/xattr_test.go:13:6: func `xattrSupported` is unused (unused) func xattrSupported(path string) bool { ^ internal/fusefrontend_reverse/rpath.go:20:22: func `(*RootNode).abs` is unused (unused) func (rfs *RootNode) abs(relPath string, err error) (string, error) { ^ tests/matrix/matrix_test.go:310:6: `sContains` is unused (deadcode) func sContains(haystack []string, needle string) bool {
Diffstat (limited to 'tests/matrix')
-rw-r--r--tests/matrix/matrix_test.go10
1 files changed, 0 insertions, 10 deletions
diff --git a/tests/matrix/matrix_test.go b/tests/matrix/matrix_test.go
index 5906b3c..5cc5251 100644
--- a/tests/matrix/matrix_test.go
+++ b/tests/matrix/matrix_test.go
@@ -306,16 +306,6 @@ func TestFileHoles(t *testing.T) {
}
}
-// sContains - does the slice of strings "haystack" contain "needle"?
-func sContains(haystack []string, needle string) bool {
- for _, element := range haystack {
- if element == needle {
- return true
- }
- }
- return false
-}
-
func TestRmwRace(t *testing.T) {
runtime.GOMAXPROCS(10)