aboutsummaryrefslogtreecommitdiffstats
path: root/util/lamport/persisted_clock_test.go
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2020-12-08 15:17:22 +0100
committerGitHub <noreply@github.com>2020-12-08 15:17:22 +0100
commitbf476f98d1656850e2f3fd349adea504007a8313 (patch)
tree595f3875590c89fe1c5a30e2e732f8aee9b35361 /util/lamport/persisted_clock_test.go
parent54d123c6753d053df8400beea316e13690c851f4 (diff)
parent8128bb79b0db9023a98c356e4e173d846057c577 (diff)
downloadgit-bug-bf476f98d1656850e2f3fd349adea504007a8313.tar.gz
Merge pull request #510 from MichaelMure/repo-rework
Repo rework
Diffstat (limited to 'util/lamport/persisted_clock_test.go')
-rw-r--r--util/lamport/persisted_clock_test.go8
1 files changed, 3 insertions, 5 deletions
diff --git a/util/lamport/persisted_clock_test.go b/util/lamport/persisted_clock_test.go
index aacec3bf..9ef690da 100644
--- a/util/lamport/persisted_clock_test.go
+++ b/util/lamport/persisted_clock_test.go
@@ -1,18 +1,16 @@
package lamport
import (
- "io/ioutil"
- "path"
"testing"
+ "github.com/go-git/go-billy/v5/memfs"
"github.com/stretchr/testify/require"
)
func TestPersistedClock(t *testing.T) {
- dir, err := ioutil.TempDir("", "")
- require.NoError(t, err)
+ root := memfs.New()
- c, err := NewPersistedClock(path.Join(dir, "test-clock"))
+ c, err := NewPersistedClock(root, "test-clock")
require.NoError(t, err)
testClock(t, c)