Created
November 15, 2020 14:31
-
-
Save javierfernandes/ff31a346f7f6f3e49414428c1326e6af to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
// collapsed selection | |
['DAVID {Hello [|]World} FINCH', true], | |
['DAVID {[|]Hello World} FINCH', true], | |
['DAVID {Hello World[|]} FINCH', true], | |
['DAVID [|]{Hello World} FINCH', false], | |
['DAVID {Hello World}[|] FINCH', false], | |
// expanded selection | |
['DAVID {Hel[>lo Wo>]rld} FINCH', true], | |
['DAVID {[>Hello World>]} FINCH', true], | |
['DAVID [>{Hello Wo>]rld} FINCH', false], | |
['DAVID {Hello [>World} >]FINCH', false], | |
['DAVID [>{Hello World}>] FINCH', false] | |
].forEach(([text, expected]) => { | |
it(`${text} -> ${expected}`, () => | |
expectIsWithin(text).toBe(expected) | |
) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment