Repository navigation
Add openfga-language, a pest port of the OpenFGA DSL grammar - #3
LucaCappelletti94 wants to merge 2 commits into
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## d1-openfga-model #3 +/- ##
===================================================
Coverage 100.00% 100.00%
===================================================
Files 1 4 +3
Lines 24 273 +249
===================================================
+ Hits 24 273 +249 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
openfga-language parses OpenFGA DSL into the openfga-model types under no_std. Its grammar is a rule-by-rule pest port of OpenFGALexer.g4 and OpenFGAParser.g4, and each pest rule names the ANTLR rule it ports, so a later grammar change upstream maps to an edit here. The lowering mirrors the Go transformer, including the errors it raises while transforming.
All transformer cases of openfga/language lower to their expected models, and the syntax cases fail exactly when they list errors, which is the Go test's criterion since it does not compare ANTLR messages either.