Skip to content

Commit

Permalink
Fix tests that depended on an existing bug
Browse files Browse the repository at this point in the history
  • Loading branch information
marijnh committed Nov 2, 2023
1 parent 8c2e5ca commit cecef4e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/webtest-composition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ describe("Composition", () => {
})

it("applies compositions at secondary cursors", () => {
let cm = requireFocus(tempView("one\ntwo"))
let cm = requireFocus(tempView("one\ntwo", EditorState.allowMultipleSelections.of(true)))
cm.dispatch({selection: EditorSelection.create([EditorSelection.cursor(3), EditorSelection.cursor(7)], 0)})
compose(cm, () => up(cm.domAtPos(2).node as Text, "·"), [
n => up(n, "-", 3, 4),
Expand All @@ -354,7 +354,7 @@ describe("Composition", () => {
})

it("applies compositions at secondary cursors even when the change is before the cursor", () => {
let cm = requireFocus(tempView("one\ntwo"))
let cm = requireFocus(tempView("one\ntwo", EditorState.allowMultipleSelections.of(true)))
cm.dispatch({selection: EditorSelection.create([EditorSelection.cursor(3), EditorSelection.cursor(7)], 0)})
compose(cm, () => up(cm.domAtPos(2).node as Text, "X"), [
n => up(n, "Y"),
Expand Down

0 comments on commit cecef4e

Please sign in to comment.