void () { var file = myFixture.configureByText("a.txt", "ab"); var base = psiFragment(file, 0, 2); for (int i = 0; i <= 2; i++) { var withMarkup = base.excludeRanges(List.of(new TextContent.Exclusion(i, i, TextContent.ExclusionKind.markup))); Assertions.assertArrayEquals(new int[]{i}, withMarkup.markupOffsets(), "Offset " + i); var withUnknown = withMarkup.markUnknown(TextRange.from(i, 0)); assertTrue("Offset " + i, withUnknown.hasUnknownFragmentsIn(TextRange.from(i, 0))); Assertions.assertArrayEquals(new int[0], withUnknown.markupOffsets(), "Offset " + i); } }