Package org.openrewrite.test
Class RecipeSpec
java.lang.Object
org.openrewrite.test.RecipeSpec
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionafterRecipe(UncheckedConsumer<org.openrewrite.RecipeRun> afterRecipe) SourceSpec<org.openrewrite.SourceFile>Configuration that applies to all source file inputs.beforeRecipe(UncheckedConsumer<List<org.openrewrite.SourceFile>> beforeRecipe) cycles(int cycles) <E> RecipeSpecdataTable(Class<E> rowType, UncheckedConsumer<List<E>> extract) <E,V> RecipeSpec dataTableAsCsv(Class<org.openrewrite.DataTable<?>> dataTableClass, String expect) <E,V> RecipeSpec dataTableAsCsv(String name, String expect) static RecipeSpecdefaults()executionContext(org.openrewrite.ExecutionContext executionContext) expectedCyclesThatMakeChanges(int expectedCyclesThatMakeChanges) markerPrinter(org.openrewrite.PrintOutputCapture.MarkerPrinter markerPrinter) parser(org.openrewrite.Parser.Builder parser) recipe(InputStream yaml, String... recipes) recipe(org.openrewrite.Recipe recipe) recipeExecutionContext(org.openrewrite.ExecutionContext executionContext) relativeTo(@Nullable Path relativeTo) typeValidationOptions(TypeValidation typeValidation) validateRecipeSerialization(boolean validate)
-
Constructor Details
-
RecipeSpec
public RecipeSpec()
-
-
Method Details
-
defaults
-
allSources
Configuration that applies to all source file inputs. -
recipe
-
recipe
-
recipe
-
parser
- Parameters:
parser- The parser supplier to use when a matching source file is found.- Returns:
- The current recipe spec.
-
executionContext
-
recipeExecutionContext
-
markerPrinter
-
relativeTo
-
cycles
-
beforeRecipe
-
afterRecipe
-
dataTable
@Incubating(since="7.35.0") public <E> RecipeSpec dataTable(Class<E> rowType, UncheckedConsumer<List<E>> extract) -
dataTableAsCsv
@Incubating(since="7.35.0") public <E,V> RecipeSpec dataTableAsCsv(Class<org.openrewrite.DataTable<?>> dataTableClass, String expect) -
dataTableAsCsv
-
validateRecipeSerialization
-
expectedCyclesThatMakeChanges
-
typeValidationOptions
-