|
|
@ -48,6 +48,8 @@ func TestEdits(t *testing.T) { |
|
|
|
defer w.Clean() |
|
|
|
defer w.Clean() |
|
|
|
|
|
|
|
|
|
|
|
const title = "sometitle" |
|
|
|
const title = "sometitle" |
|
|
|
|
|
|
|
var contentPath = path.Join("content", title+".md") |
|
|
|
|
|
|
|
|
|
|
|
w.CH.NewContent(title, "") |
|
|
|
w.CH.NewContent(title, "") |
|
|
|
|
|
|
|
|
|
|
|
send := []acedoc.Delta{ |
|
|
|
send := []acedoc.Delta{ |
|
|
@ -58,7 +60,7 @@ func TestEdits(t *testing.T) { |
|
|
|
var mtx sync.Mutex |
|
|
|
var mtx sync.Mutex |
|
|
|
received := []acedoc.Delta{} |
|
|
|
received := []acedoc.Delta{} |
|
|
|
|
|
|
|
|
|
|
|
doc, err := w.CH.client(title + ".md") |
|
|
|
doc, err := w.CH.client(contentPath) |
|
|
|
if err != nil { |
|
|
|
if err != nil { |
|
|
|
t.Fatal("error creating document client:", err) |
|
|
|
t.Fatal("error creating document client:", err) |
|
|
|
} |
|
|
|
} |
|
|
@ -71,7 +73,7 @@ func TestEdits(t *testing.T) { |
|
|
|
return nil |
|
|
|
return nil |
|
|
|
})) |
|
|
|
})) |
|
|
|
|
|
|
|
|
|
|
|
_, ok := w.CH.hasdocref(title + ".md") |
|
|
|
_, ok := w.CH.hasdocref(contentPath) |
|
|
|
if !ok { |
|
|
|
if !ok { |
|
|
|
t.Fatal("expected there to be an established client") |
|
|
|
t.Fatal("expected there to be an established client") |
|
|
|
} |
|
|
|
} |
|
|
|