Strumenta / antlr-kotlin

Support for Kotlin as a target for ANTLR 4
Apache License 2.0
222 stars 47 forks source link

Set up grammar testing #119

Closed lppedd closed 8 months ago

lppedd commented 8 months ago

The way grammar tests are set up resembles how antlr4test-maven-plugin does it.

We have a base class GrammarTest that can be extended to support new grammars. Each implementation may execute multiple test runs against multiple sample files.

ftomassetti commented 8 months ago

It looks good to me. Should we go on and merge?

Btw, I released a new version after merging the previous 2 PRs. The target and the runtime should be available on Maven Central in the near future and the gradle plugin is available on the gradle portal: https://plugins.gradle.org/plugin/com.strumenta.antlr-kotlin

lppedd commented 8 months ago

You can merge imo.

I'm also going to open another PR in 10 minutes, which is urgent, in the sense that there were missing property overrides in Kotlin.stg that I did not notice during the cleanup.