Add provides information to rules in tests

This commit is contained in:
Jeroen Engels 2022-10-18 00:04:52 +02:00
parent f164cecdf2
commit 155b6c6f23
12 changed files with 12 additions and 0 deletions

View File

@ -54,6 +54,7 @@ rule =
Rule.newProjectRuleSchema "Docs.UpToDateReadmeLinks" initialProjectContext
|> Rule.withElmJsonProjectVisitor elmJsonVisitor
|> Rule.withReadmeProjectVisitor readmeVisitor
|> Rule.providesFixesForProjectRule
|> Rule.fromProjectRuleSchema

View File

@ -68,6 +68,7 @@ rule : Rule
rule =
Rule.newModuleRuleSchemaUsingContextCreator "NoDebug.Log" initContext
|> Rule.withExpressionEnterVisitor expressionVisitor
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -61,6 +61,7 @@ rule =
Rule.newModuleRuleSchema "NoExposingEverything" ExposingOk
|> Rule.withModuleDefinitionVisitor moduleDefinitionVisitor
|> Rule.withDeclarationListVisitor declarationListVisitor
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -25,6 +25,7 @@ rule config =
|> Rule.withImportVisitor (importVisitor options)
|> NameVisitor.withNameVisitor moduleCallVisitor
|> Rule.withFinalModuleEvaluation (finalEvaluation options.lookupAlias)
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -96,6 +96,7 @@ rule =
, fromModuleToProject = fromModuleToProjectContext
, foldProjectContexts = foldProjectContexts
}
|> Rule.providesFixesForProjectRule
|> Rule.fromProjectRuleSchema

View File

@ -97,6 +97,7 @@ rule =
{ valueVisitor = valueVisitor
, typeVisitor = typeVisitor
}
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -54,6 +54,7 @@ rule : Rule
rule =
Rule.newModuleRuleSchemaUsingContextCreator "NoNegationInIfCondition" initialContext
|> Rule.withExpressionEnterVisitor expressionVisitor
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -155,6 +155,7 @@ rule =
|> Rule.withDeclarationEnterVisitor declarationVisitor
|> Rule.withExpressionEnterVisitor expressionEnterVisitor
|> Rule.withExpressionExitVisitor expressionExitVisitor
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -46,6 +46,7 @@ rule : Rule
rule =
Rule.newModuleRuleSchema "NoRedundantConcat" ()
|> Rule.withSimpleExpressionVisitor expressionVisitor
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -81,6 +81,7 @@ rule : Rule
rule =
Rule.newModuleRuleSchema "NoSimpleLetBody" ()
|> Rule.withSimpleExpressionVisitor expressionVisitor
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -78,6 +78,7 @@ rule =
|> Rule.withExpressionExitVisitor expressionExitVisitor
|> Rule.withLetDeclarationEnterVisitor letDeclarationEnterVisitor
|> Rule.withLetDeclarationExitVisitor letDeclarationExitVisitor
|> Rule.providesFixesForModuleRule
|> Rule.fromModuleRuleSchema

View File

@ -603,6 +603,7 @@ rule (Configuration config) =
, fromModuleToProject = fromModuleToProject
, foldProjectContexts = \_ previous -> previous
}
|> Rule.providesFixesForProjectRule
|> Rule.fromProjectRuleSchema