Package com.vladsch.flexmark.test.util
Interface SpecExampleProcessor
- All Known Implementing Classes:
ComboSpecTestCase
,FormatterSpecTest
,FormatterTranslationSpecTestBase
,FullSpecTestCase
,RendererSpecTest
,RenderingTestCase
,TranslationFormatterSpecTest
public interface SpecExampleProcessor
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addFullSpecExample
(@NotNull SpecExampleRenderer exampleRenderer, @NotNull SpecExampleParse exampleParse, @Nullable DataHolder exampleOptions, boolean ignoredTestCase, @NotNull String html, @Nullable String ast) Called by DumpSpecReader for each example when processing full test specdefault @NotNull SpecExample
checkExample
(@NotNull SpecExample example) Allows tests to modify example during reading (DumpSpecReader)@NotNull SpecExampleRenderer
getSpecExampleRenderer
(@NotNull SpecExample example, @Nullable DataHolder exampleOptions) Get spec renderer for an example spec@Nullable DataHolder
Customize options for an example
-
Method Details
-
options
Customize options for an example- Parameters:
option
- name of the options set to use- Returns:
- options or null to use default
-
checkExample
Allows tests to modify example during reading (DumpSpecReader)- Parameters:
example
- example as it is in the test or spec file- Returns:
- modified example if needed
-
getSpecExampleRenderer
@NotNull @NotNull SpecExampleRenderer getSpecExampleRenderer(@NotNull @NotNull SpecExample example, @Nullable @Nullable DataHolder exampleOptions) Get spec renderer for an example spec- Parameters:
example
- spec exampleexampleOptions
- example custom options- Returns:
- spec renderer for given example and options
-
addFullSpecExample
void addFullSpecExample(@NotNull @NotNull SpecExampleRenderer exampleRenderer, @NotNull @NotNull SpecExampleParse exampleParse, @Nullable @Nullable DataHolder exampleOptions, boolean ignoredTestCase, @NotNull @NotNull String html, @Nullable @Nullable String ast) Called by DumpSpecReader for each example when processing full test spec- Parameters:
exampleRenderer
- example rendererexampleParse
- example parse stateexampleOptions
- example optionsignoredTestCase
- true if ignored examplehtml
- html used for comparison to expected htmlast
- ast used for comparison to expected ast
-