Skip to content

Commit

Permalink
test: fix error
Browse files Browse the repository at this point in the history
  • Loading branch information
luolonghao committed Oct 23, 2024
1 parent 9f656c3 commit 640e188
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions tests/editor.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ describe('editor', () => {
editor.unmount();
});

it('focus method: focus on text', () => {
it('method: focus', () => {
const editor = new Editor({
root: rootNode,
});
Expand All @@ -394,20 +394,6 @@ describe('editor', () => {
editor.unmount();
});

it('focus method: focus on a box', () => {
const editor = new Editor({
root: rootNode,
value: '<p>foo<lake-box type="inline" name="inlineBox" focus="start"></lake-box>bar</p>',
});
editor.render();
editor.focus();
editor.selection.selectBox(editor.container.find('lake-box'));
expect(editor.hasFocus).to.equal(true);
editor.blur();
expect(editor.hasFocus).to.equal(false);
editor.unmount();
});

it('method: scrollToCaret', () => {
rootNode.css('width', '200px');
rootNode.css('min-width', '200px');
Expand Down

0 comments on commit 640e188

Please sign in to comment.