summaryrefslogtreecommitdiffstats
path: root/src/chunklist_test.go
diff options
context:
space:
mode:
authorJunegunn Choi <junegunn.c@gmail.com>2017-08-16 12:26:06 +0900
committerJunegunn Choi <junegunn.c@gmail.com>2017-08-16 12:26:06 +0900
commit0558dfee795c297abef27a3abaa232c73d8a042d (patch)
tree0ff7906ad4ba93c8615fa33b80ac955ff488ea56 /src/chunklist_test.go
parent487c8fe88f4cfcc55850b8aef73665b1d09b8fe0 (diff)
Remove count field from ChunkList
Diffstat (limited to 'src/chunklist_test.go')
-rw-r--r--src/chunklist_test.go7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/chunklist_test.go b/src/chunklist_test.go
index c8d33a67..6c1d09eb 100644
--- a/src/chunklist_test.go
+++ b/src/chunklist_test.go
@@ -11,9 +11,8 @@ func TestChunkList(t *testing.T) {
// FIXME global
sortCriteria = []criterion{byScore, byLength}
- cl := NewChunkList(func(item *Item, s []byte, i int) bool {
+ cl := NewChunkList(func(item *Item, s []byte) bool {
item.text = util.ToChars(s)
- item.text.Index = int32(i * 2)
return true
})
@@ -44,9 +43,7 @@ func TestChunkList(t *testing.T) {
t.Error("Snapshot should contain only two items")
}
if chunk1.items[0].text.ToString() != "hello" ||
- chunk1.items[0].Index() != 0 ||
- chunk1.items[1].text.ToString() != "world" ||
- chunk1.items[1].Index() != 2 {
+ chunk1.items[1].text.ToString() != "world" {
t.Error("Invalid data")
}
if chunk1.IsFull() {