Search in sources :

Example 6 with SubstitutionWithoutCssSpanStrategy

use of org.eclipse.mylyn.wikitext.html.internal.SubstitutionWithoutCssSpanStrategy in project mylyn.docs by eclipse.

the class SpanStrategiesTest method spanWithTextDecorationLinethroughToDeleted.

@Test
public void spanWithTextDecorationLinethroughToDeleted() {
    SpanStrategies strategies = new SpanStrategies(Sets.newHashSet(SpanType.DELETED), Collections.<SpanHtmlElementStrategy>emptyList());
    SpanStrategy strategy = strategies.getStrategy(SpanType.SPAN, new Attributes(null, null, "text-decoration:  line-through;", null));
    assertTrue(strategy instanceof SubstitutionWithoutCssSpanStrategy);
    assertEquals(SpanType.DELETED, ((SubstitutionWithoutCssSpanStrategy) strategy).getType());
}
Also used : SubstitutionWithoutCssSpanStrategy(org.eclipse.mylyn.wikitext.html.internal.SubstitutionWithoutCssSpanStrategy) SupportedSpanStrategy(org.eclipse.mylyn.wikitext.html.internal.SupportedSpanStrategy) UnsupportedSpanStrategy(org.eclipse.mylyn.wikitext.html.internal.UnsupportedSpanStrategy) SubstitutionSpanStrategy(org.eclipse.mylyn.wikitext.html.internal.SubstitutionSpanStrategy) SpanStrategy(org.eclipse.mylyn.wikitext.html.internal.SpanStrategy) Attributes(org.eclipse.mylyn.wikitext.parser.Attributes) SpanStrategies(org.eclipse.mylyn.wikitext.html.internal.SpanStrategies) SubstitutionWithoutCssSpanStrategy(org.eclipse.mylyn.wikitext.html.internal.SubstitutionWithoutCssSpanStrategy) Test(org.junit.Test)

Aggregations

SubstitutionWithoutCssSpanStrategy (org.eclipse.mylyn.wikitext.html.internal.SubstitutionWithoutCssSpanStrategy)6 Attributes (org.eclipse.mylyn.wikitext.parser.Attributes)6 Test (org.junit.Test)6 SpanStrategies (org.eclipse.mylyn.wikitext.html.internal.SpanStrategies)4 SpanStrategy (org.eclipse.mylyn.wikitext.html.internal.SpanStrategy)4 SubstitutionSpanStrategy (org.eclipse.mylyn.wikitext.html.internal.SubstitutionSpanStrategy)4 SupportedSpanStrategy (org.eclipse.mylyn.wikitext.html.internal.SupportedSpanStrategy)4 UnsupportedSpanStrategy (org.eclipse.mylyn.wikitext.html.internal.UnsupportedSpanStrategy)4 EventDocumentBuilder (org.eclipse.mylyn.wikitext.parser.builder.EventDocumentBuilder)2 BeginSpanEvent (org.eclipse.mylyn.wikitext.parser.builder.event.BeginSpanEvent)2 CompositeSpanStrategy (org.eclipse.mylyn.wikitext.html.internal.CompositeSpanStrategy)1 DocumentBuilderEvent (org.eclipse.mylyn.wikitext.parser.builder.event.DocumentBuilderEvent)1 DocumentBuilderEvents (org.eclipse.mylyn.wikitext.parser.builder.event.DocumentBuilderEvents)1 EndSpanEvent (org.eclipse.mylyn.wikitext.parser.builder.event.EndSpanEvent)1