Top Methods
com.vladsch.flexmark.test.util

public Interface SpecExampleProcessor

Known Direct Implementers
com.vladsch.flexmark.test.util.FullSpecTestCase, com.vladsch.flexmark.test.util.RenderingTestCase
Imports
com.vladsch.flexmark.test.util.spec.SpecExample, com.vladsch.flexmark.util.data.DataHolder, org.jetbrains.annotations.NotNull, .Nullable

Method Summary

Modifier and TypeMethod and Description
public void
addFullSpecExample(@NotNull SpecExampleRenderer
example renderer
exampleRenderer
,
@NotNull SpecExampleParse
example parse state
exampleParse
,
@Nullable DataHolder
example options
exampleOptions
,
boolean
true if ignored example
ignoredTestCase
,
@NotNull String
html used for comparison to expected html
html
,
@Nullable String
ast used for comparison to expected ast
ast
)

Called by DumpSpecReader for each example when processing full test spec

public default @NotNull SpecExample

Returns:

modified example if needed
checkExample
(@NotNull SpecExample
example as it is in the test or spec file
example
)

Allows tests to modify example during reading (DumpSpecReader)

public @NotNull SpecExampleRenderer

Returns:

spec renderer for given example and options
getSpecExampleRenderer
(@NotNull SpecExample
spec example
example
,
@Nullable DataHolder
example custom options
exampleOptions
)

Get spec renderer for an example spec

public @Nullable DataHolder

Returns:

options or null to use default
options
(@NotNull String
name of the options set to use
option
)

Customize options for an example

Method Detail

addFullSpecExampleback to summary
public void 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 spec

Parameters
exampleRenderer:@NotNull SpecExampleRenderer

example renderer

exampleParse:@NotNull SpecExampleParse

example parse state

exampleOptions:@Nullable DataHolder

example options

ignoredTestCase:boolean

true if ignored example

html:@NotNull String

html used for comparison to expected html

ast:@Nullable String

ast used for comparison to expected ast

checkExampleback to summary
public default @NotNull SpecExample checkExample(@NotNull SpecExample example)

Allows tests to modify example during reading (DumpSpecReader)

Parameters
example:@NotNull SpecExample

example as it is in the test or spec file

Returns:@NotNull SpecExample

modified example if needed

Annotations
@NotNull
getSpecExampleRendererback to summary
public @NotNull SpecExampleRenderer getSpecExampleRenderer(@NotNull SpecExample example, @Nullable DataHolder exampleOptions)

Get spec renderer for an example spec

Parameters
example:@NotNull SpecExample

spec example

exampleOptions:@Nullable DataHolder

example custom options

Returns:@NotNull SpecExampleRenderer

spec renderer for given example and options

Annotations
@NotNull
optionsback to summary
public @Nullable DataHolder options(@NotNull String option)

Customize options for an example

Parameters
option:@NotNull String

name of the options set to use

Returns:@Nullable DataHolder

options or null to use default

Annotations
@Nullable