Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
it('supports leaf nodes with with nested inline atom nodes', () => {
const node = atomContainer(atomBlock());
const {
state: { selection },
} = createEditor(doc(p('abcd'), atomContainer(atomBlock()), ''));
const position = findPositionOfNodeBefore(selection);
expect(position).toEqual({ pos: 6, start: 7, end: 9, node });
});
});
it('supports leaf nodes with with nested inline atom nodes', () => {
const node = atomContainer(atomBlock());
const {
state: { selection },
} = createEditor(doc(p('abcd'), atomContainer(atomBlock()), ''));
const position = findPositionOfNodeBefore(selection);
expect(position).toEqual({ pos: 6, start: 7, end: 9, node });
});
});