Fix merge

This commit is contained in:
Clément Fournier
2022-03-03 20:46:01 +01:00
parent 9d1c1860cb
commit 9808c743d2
8 changed files with 115 additions and 212 deletions

View File

@@ -252,5 +252,12 @@ abstract class BaseParsingHelper<Self : BaseParsingHelper<Self, T>, T : RootNode
}
fun executeRuleOnResource(rule: Rule, resourcePath: String): Report =
executeRule(rule, readResource(resourcePath))
executeRule(rule, code = readResource(resourcePath))
fun executeRuleOnFile(rule: Rule, path: Path): Report =
executeRule(
rule,
code = Files.newBufferedReader(path).readText(),
fileName = path.toString()
)
}