Added a benchmark for ScanDirectory().
This commit is contained in:
parent
cbe0292e4c
commit
df3ea75ca9
13
pkg/files/files_test.go
Normal file
13
pkg/files/files_test.go
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
package files
|
||||||
|
|
||||||
|
import "testing"
|
||||||
|
|
||||||
|
const path = "/mnt/data/music/Various"
|
||||||
|
const urlBase = "/srv/ftp/"
|
||||||
|
|
||||||
|
func BenchmarkScanDirectory(b *testing.B) {
|
||||||
|
for i := 0; i < b.N; i++ {
|
||||||
|
/*e, _, _ :=*/ ScanDirectory(path, urlBase)
|
||||||
|
// b.Log(e[len(e)-1], len(e))
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user