From 2cd98a3bcd18870da4404693212119dd8ccfaf68 Mon Sep 17 00:00:00 2001 From: n-peugnet Date: Sat, 28 Aug 2021 20:54:34 +0200 Subject: refactor(chunks): use more interfaces --- sketch_test.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'sketch_test.go') diff --git a/sketch_test.go b/sketch_test.go index 2f568e6..86a2c58 100644 --- a/sketch_test.go +++ b/sketch_test.go @@ -2,14 +2,13 @@ package main import ( "path" + "reflect" "testing" - - "github.com/google/go-cmp/cmp" ) func TestSketchChunk(t *testing.T) { dataDir := path.Join("test", "data", "repo_8k") - chunks := make(chan Chunk, 16) + chunks := make(chan StoredChunk, 16) repo := NewRepo(dataDir) versions := repo.loadVersions() go repo.loadChunks(versions, chunks) @@ -21,7 +20,7 @@ func TestSketchChunk(t *testing.T) { t.Error(err) } expected := Sketch{429857165471867, 6595034117354675, 8697818304802825} - if !cmp.Equal(sketch, expected) { + if !reflect.DeepEqual(sketch, expected) { t.Errorf("Sketch does not match, expected: %d, actual: %d", expected, sketch) } } -- cgit v1.2.3