]> Sergey Matveev's repositories - btrtrc.git/blobdiff - torrent_mmap_test.go
Fixes for wasm
[btrtrc.git] / torrent_mmap_test.go
diff --git a/torrent_mmap_test.go b/torrent_mmap_test.go
new file mode 100644 (file)
index 0000000..8114309
--- /dev/null
@@ -0,0 +1,18 @@
+//go:build !wasm
+// +build !wasm
+
+package torrent
+
+import (
+       "testing"
+
+       "github.com/anacrolix/torrent/storage"
+)
+
+func TestEmptyFilesAndZeroPieceLengthWithMMapStorage(t *testing.T) {
+       cfg := TestingConfig(t)
+       ci := storage.NewMMap(cfg.DataDir)
+       defer ci.Close()
+       cfg.DefaultStorage = ci
+       testEmptyFilesAndZeroPieceLength(t, cfg)
+}