use of jodd.decora.parser.PageRegionExtractor.RegionMarker in project jodd by oblac.
the class PageRegionExtractorTest method testEndRegionMarkersNotEmpty.
@Test(expected = DecoraException.class)
public final void testEndRegionMarkersNotEmpty() {
// setup
regionMarkers.add(new RegionMarker("TEST"));
setInternalState(pageRegionExtractor, "regionMarkers", regionMarkers);
// when
pageRegionExtractor.end();
// then
fail("A DecorationException must have occured because regionMarkers is not empty.");
}
use of jodd.decora.parser.PageRegionExtractor.RegionMarker in project jodd by oblac.
the class PageRegionExtractorTest method testTag.
@Test(expected = DecoraException.class)
public final void testTag() {
// setup
Tag tag = mock(Tag.class);
when(tag.getType()).thenReturn(TagType.END);
regionMarkers.add(new RegionMarker("TEST"));
setInternalState(pageRegionExtractor, "regionMarkers", regionMarkers);
// when
pageRegionExtractor.tag(tag);
// then
fail("A DecoraException must have occured because tag parameter not matches with any decoraTags.");
}
Aggregations