{"id":19564366,"url":"https://github.com/antlr/antlr4test-maven-plugin","last_synced_at":"2025-09-22T08:29:04.175Z","repository":{"id":21617670,"uuid":"91368609","full_name":"antlr/antlr4test-maven-plugin","owner":"antlr","description":"A maven plugin used to test the grammars-v4 repo grammars","archived":false,"fork":false,"pushed_at":"2023-06-19T20:09:57.000Z","size":239,"stargazers_count":18,"open_issues_count":21,"forks_count":17,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-08-05T00:22:13.641Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/antlr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-05-15T18:01:54.000Z","updated_at":"2025-04-12T15:16:43.000Z","dependencies_parsed_at":"2024-11-11T05:24:11.375Z","dependency_job_id":"2268d016-13c5-445b-aa3d-f8382d9d548f","html_url":"https://github.com/antlr/antlr4test-maven-plugin","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/antlr/antlr4test-maven-plugin","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/antlr%2Fantlr4test-maven-plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/antlr%2Fantlr4test-maven-plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/antlr%2Fantlr4test-maven-plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/antlr%2Fantlr4test-maven-plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/antlr","download_url":"https://codeload.github.com/antlr/antlr4test-maven-plugin/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/antlr%2Fantlr4test-maven-plugin/sbom","scorecard":{"id":199252,"data":{"date":"2025-08-11","repo":{"name":"github.com/antlr/antlr4test-maven-plugin","commit":"fbba99e1ecebe03681e1269a0a1fba95f75550c3"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.9,"checks":[{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Code-Review","score":0,"reason":"Found 0/24 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/main.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/antlr/antlr4test-maven-plugin/main.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/antlr/antlr4test-maven-plugin/main.yml/master?enable=pin","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: BSD 3-Clause \"New\" or \"Revised\" License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 6 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":4,"reason":"6 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-5mg8-w23w-74h3","Warn: Project is vulnerable to: GHSA-7g45-4rm6-3mm3","Warn: Project is vulnerable to: GHSA-78wr-2p64-hpwj","Warn: Project is vulnerable to: GHSA-j288-q9x7-2f5v","Warn: Project is vulnerable to: GHSA-rhgr-952r-6p8q","Warn: Project is vulnerable to: GHSA-2f88-5hg8-9x2x"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-16T22:30:28.124Z","repository_id":21617670,"created_at":"2025-08-16T22:30:28.124Z","updated_at":"2025-08-16T22:30:28.124Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276370504,"owners_count":25630467,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-22T02:00:08.972Z","response_time":79,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-11T05:21:40.076Z","updated_at":"2025-09-22T08:29:04.144Z","avatar_url":"https://github.com/antlr.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"![CI](https://github.com/antlr/antlr4test-maven-plugin/workflows/CI/badge.svg)\n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/47b1ccdfcf5b4af4abdef44328f8cb26)](https://www.codacy.com/app/teverett/antlr4test-maven-plugin?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=teverett/antlr4test-maven-plugin\u0026amp;utm_campaign=Badge_Grade)\n[![DepShield Badge](https://depshield.sonatype.org/badges/teverett/antlr4test-maven-plugin/depshield.svg)](https://depshield.github.io)\n\n# antlr4test-maven-plugin\n\nMaven Mojo for testing [Antlr4](http://www.antlr.org/) Grammars\n\n## Maven Coordinates\n\n```xml\n\u003cgroupId\u003ecom.khubla.antlr\u003c/groupId\u003e\n\u003cartifactId\u003eantlr4test-maven-plugin\u003c/artifactId\u003e\n\u003cversion\u003e1.18\u003c/version\u003e\n\u003cpackaging\u003ejar\u003c/packaging\u003e\n```\n\n## Example usage\n\n```xml\n\u003cplugin\u003e\n\t\u003cgroupId\u003eorg.antlr\u003c/groupId\u003e\n\t\u003cartifactId\u003eantlr4test-maven-plugin\u003c/artifactId\u003e\n\t\u003cconfiguration\u003e\n\t\t\u003cverbose\u003etrue\u003c/verbose\u003e\n\t\t\u003cshowTree\u003etrue\u003c/showTree\u003e\n\t\t\u003centryPoint\u003eequation\u003c/entryPoint\u003e\n\t\t\u003cgrammarName\u003etnt\u003c/grammarName\u003e\n\t\t\u003cpackageName\u003e\u003c/packageName\u003e\n\t\t\u003ctestFileExtension\u003e.txt\u003c/testFileExtension\u003e\n\t\t\u003cexampleFiles\u003esrc/test/resources/examples\u003c/exampleFiles\u003e\n\t\t\u003cgrammarInitializer\u003ecom.my.package.MyGrammarInitializer\u003c/grammarInitializer\u003e\n\t\u003c/configuration\u003e\n\u003c/plugin\u003e\n```\n\n## Parameters\n\n### grammarName\n\nRequired name of the grammar.  This should match the name of the grammar defined in the grammar \".g4\" file.\n\n```xml\n\u003cgrammarName\u003ePHP\u003c/grammarName\u003e\n```\n\n### caseInsensitiveType\n\nAn optional enum parameter used to enable a caseInsensitive lexer for case-insensitive languages such as PHP, Pascal, T-SQL, etc.\n\nAvailable values:\n* `None` - does not activate a case insensitive mode (by default).\n* `lower` - all token values should be written in lower-case: `TOKEN: 'asdf'`.\n* `UPPER` - all token values should be written in UPPER-case: `TOKEN: 'ASDF'`.\n\n```xml\n\u003ccaseInsensitiveType\u003eUPPER\u003c/caseInsensitiveType\u003e\n```\n\n### entryPoint\n\nRequired name of the grammar rule to use as the test entry point\n\n```xml\n\u003centryPoint\u003ehtmlDocument\u003c/entryPoint\u003e\n```\n### binary\n\nOptionally treat file as binary\n\n```xml\n\u003cbinary\u003etrue\u003c/binary\u003e\n```\n\n### enabled\n\nOptional boolean enable-disable flag\n\n```xml\n\u003cenabled\u003etrue\u003c/enabled\u003e\n```\n\n### verbose\n\nOptionally produce verbose output\n\n```xml\n\u003cverbose\u003etrue\u003c/verbose\u003e\n```\n\n### showTree\n\nOptionally show the LISP grammar tree\n\n```xml\n\u003cshowTree\u003efalse\u003c/showTree\u003e\n```\n\n### exampleFiles\n\nRequired relative path to the example files\n\n```xml\n\u003cexampleFiles\u003esrc/test/resources/examples/\u003c/exampleFiles\u003e\n```\n\n### packageName\n\nOptional package name to find the Lexer and Parser classes in\n\n```xml\n\u003cpackageName\u003e\u003c/packageName\u003e\n```\n\n### testFileExtension \n\nOptional file extension of test files\n\n```xml\n\u003ctestFileExtension\u003e.php\u003c/testFileExtension\u003e\n```\n\n### fileEncoding\n\nOptional file encoding. The default value is UTF-8.\n\n```xml\n\u003cfileEncoding\u003eShift_JIS\u003c/fileEncoding\u003e\n```\n\n### grammarInitializer\n\nOptional full qualified name of a Java class that implements com.khubla.antlr.antlr4test.GrammarInitializer interface.\n\n```xml\n\u003cgrammarInitializer\u003ecom.my.package.MyGrammarInitializer\u003c/grammarInitializer\u003e\n```\n\nWhen used, allows the Lexer and/or Parser to be initialized **before** grammar test starts.\nThis option is typically used when your grammar uses **superClass** antlr4 option to override/extend default Lexer and/or Parser behavior and need to be initialized somehow before use.\n\nOne instance will be created with default constructor for each file being parsed and initialize method will be called with the Lexer and Parser instances that will be used in the tests.\nThe class that implements GrammarInitializer should implement the following signature.\n\n```java\npublic void initialize(Lexer lexer, Parser parser)\n```\n\n## Multiple Test Scenarios\n\nA new optional configuration style was created to allow multiple test scenarios for the grammar.\nA test scenario is a set of configuration parameters used to test a particular scenario.\nThe same configuration parameters used in traditional style can be used within test scenarios.\n\nIts particularly useful for grammars that allows multiple configuration options through the use of **superClass** antlr4 option.\nTest scenarios will probably be used in conjunction with grammarInitializer parameter, allowing tests for distinct sets of grammar options.\nAll configuration parameters are allowed within a test scenario. Here is an example of this new configuration style.\n\n```xml\n\u003cplugin\u003e\n\t\u003cgroupId\u003eorg.antlr\u003c/groupId\u003e\n\t\u003cartifactId\u003eantlr4test-maven-plugin\u003c/artifactId\u003e\n\t\u003cconfiguration\u003e\n\t\t\u003cscenarios\u003e\n\t\t\t\u003cscenario\u003e\n\t\t\t\t\u003cscenarioName\u003ePackage-Without-Initialization\u003c/scenarioName\u003e\n\t\t\t\t\u003cverbose\u003efalse\u003c/verbose\u003e\n\t\t\t\t\u003cshowTree\u003etrue\u003c/showTree\u003e\n\t\t\t\t\u003centryPoint\u003eattrib_list\u003c/entryPoint\u003e\n\t\t\t\t\u003cgrammarName\u003eTestGrammar\u003c/grammarName\u003e\n\t\t\t\t\u003cpackageName\u003edummy\u003c/packageName\u003e\n\t\t\t\t\u003ctestFileExtension\u003e.txt\u003c/testFileExtension\u003e\n\t\t\t\t\u003cexampleFiles\u003esrc/test/resources/noInitializationScenario/\u003c/exampleFiles\u003e\n\t\t\t\u003c/scenario\u003e\n\t\t\t\u003cscenario\u003e\n\t\t\t\t\u003cscenarioName\u003ePackage-Initialize-IgnoreSpaces\u003c/scenarioName\u003e\n\t\t\t\t\u003cverbose\u003etrue\u003c/verbose\u003e\n\t\t\t\t\u003cshowTree\u003etrue\u003c/showTree\u003e\n\t\t\t\t\u003centryPoint\u003eattrib_list\u003c/entryPoint\u003e\n\t\t\t\t\u003cgrammarName\u003eTestGrammar\u003c/grammarName\u003e\n\t\t\t\t\u003cpackageName\u003edummy\u003c/packageName\u003e\n\t\t\t\t\u003ctestFileExtension\u003e.txt\u003c/testFileExtension\u003e\n\t\t\t\t\u003cexampleFiles\u003esrc/test/resources/initializeIgnoreSpacesScenario/\u003c/exampleFiles\u003e\n\t\t\t\t\u003cgrammarInitializer\u003edummy.TestGrammarInitializer\u003c/grammarInitializer\u003e\n\t\t\t\u003c/scenario\u003e\n\t\t\u003c/scenarios\u003e\n\t\u003c/configuration\u003e\n\u003c/plugin\u003e\n```\n\nIn the example we can see a first test scenario where no initialization is made and another test scenario where a \"Ignore Space\" grammar option is initialized before tests takes place.\nYou can point to distinct example files directory in each test scenario. You can even use distinct grammars in each scenario.\nOne should not assume any particular order of execution for each scenario.\n\n### Mixing Configuration Styles\n\nYou can mix traditional configuration style with test scenario style.\nIn this case, the set of parameters created within traditional configuration style scope will be created within a \"Default Scenario\" scenario.\n\nThe following two configurations are completely equivalent.\n\n- Traditional Configuration Style\n\n```xml\n\u003cplugin\u003e\n\t\u003cgroupId\u003eorg.antlr\u003c/groupId\u003e\n\t\u003cartifactId\u003eantlr4test-maven-plugin\u003c/artifactId\u003e\n\t\u003cconfiguration\u003e\n\t\t\u003cverbose\u003etrue\u003c/verbose\u003e\n\t\t\u003cshowTree\u003etrue\u003c/showTree\u003e\n\t\t\u003centryPoint\u003eequation\u003c/entryPoint\u003e\n\t\t\u003cgrammarName\u003etnt\u003c/grammarName\u003e\n\t\t\u003ctestFileExtension\u003e.txt\u003c/testFileExtension\u003e\n\t\t\u003cexampleFiles\u003esrc/test/resources/examples\u003c/exampleFiles\u003e\n\t\t\u003cgrammarInitializer\u003ecom.my.package.MyGrammarInitializer\u003c/grammarInitializer\u003e\n\t\u003c/configuration\u003e\n\u003c/plugin\u003e\n```\n\n- Test Scenario Configuration Style\n\n```xml\n\u003cplugin\u003e\n\t\u003cgroupId\u003eorg.antlr\u003c/groupId\u003e\n\t\u003cartifactId\u003eantlr4test-maven-plugin\u003c/artifactId\u003e\n\t\u003cconfiguration\u003e\n\t\t\u003cscenarios\u003e\n\t\t\t\u003cscenario\u003e\n\t\t\t\t\u003cscenarioName\u003eDefault Scenario\u003c/scenarioName\u003e\n\t\t\t\t\u003cverbose\u003etrue\u003c/verbose\u003e\n\t\t\t\t\u003cshowTree\u003etrue\u003c/showTree\u003e\n\t\t\t\t\u003centryPoint\u003eequation\u003c/entryPoint\u003e\n\t\t\t\t\u003cgrammarName\u003etnt\u003c/grammarName\u003e\n\t\t\t\t\u003ctestFileExtension\u003e.txt\u003c/testFileExtension\u003e\n\t\t\t\t\u003cexampleFiles\u003esrc/test/resources/examples\u003c/exampleFiles\u003e\n\t\t\t\t\u003cgrammarInitializer\u003ecom.my.package.MyGrammarInitializer\u003c/grammarInitializer\u003e\n\t\t\t\u003c/scenario\u003e\n\t\t\u003c/scenarios\u003e\n\t\u003c/configuration\u003e\n\u003c/plugin\u003e\n```\n\n## Checking parsed tree\n\nSometimes you want to assure that a given input file generates an specific parsed tree. To do so, you can create sibling files to the parsed examples provided adding the .tree extension to the full name of the parsed file to ask the plugin to check if the parsed tree obtained from the file matchs an expected tree. \n\nFor example, if you have an 'examples/fileToBeParsed.txt' file, you can create a 'examples/fileToBeParsed.txt.tree' file containing the LISP style tree expected to be parsed from you file.\n\nThe checking is done by taking the parsed tree and transforming it to LISP style tree with toStringTree(parserRuleContext, parser) of class org.antlr.v4.runtime.tree.Trees. If they match, everything is fine. If don't, a Diff is generated to show where differences was found.\n\nHere is the code snippet that checks the parsed tree against the expected one:\n\n```java\n\t\tfinal File treeFile = new File(grammarFile.getAbsolutePath() + GrammarTestMojo.TREE_SUFFIX);\n\t\tif (treeFile.exists()) {\n\t\t\tfinal String lispTree = Trees.toStringTree(parserRuleContext, parser);\n\t\t\tif (null != lispTree) {\n\t\t\t\tfinal String treeFileData = FileUtils.fileRead(treeFile, scenario.getFileEncoding());\n\t\t\t\tif (null != treeFileData) {\n\t\t\t\t\tif (0 != treeFileData.compareTo(lispTree)) {\n\t\t\t\t\t\tStringBuilder sb = new StringBuilder(\n\t\t\t\t\t\t\t\t\"Parse tree does not match '\" + treeFile.getName() + \"'. Differences: \");\n\t\t\t\t\t\tfor (DiffMatchPatch.Diff diff : new DiffMatchPatch().diffMain(treeFileData, lispTree)) {\n\t\t\t\t\t\t\tsb.append(diff.toString());\n\t\t\t\t\t\t\tsb.append(\", \");\n\t\t\t\t\t\t}\n\t\t\t\t\t\tthrow new Exception(sb.toString());\n\t\t\t\t\t} else {\n\t\t\t\t\t\tlog.info(\"Parse tree for '\" + grammarFile.getName() + \"' matches '\" + treeFile.getName() + \"'\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n```\n\nA tip to use this feature is to configure the plugin to shows the parsed tree using **\u003cshowTree\u003etrue\u003c/showTree\u003e** option. Then you can check the log output manually to see if the generated tree is the expected one. If it is ok, you can copy/paste the parsed tree (only the parsed tree with no other message accessories) to the .tree file.\n\n## Checking expected errors\n\nSometimes you want to check if specific input files generate parsing errors. This can be done with the plugin by adding a new file sibling to the parsed one with .errors extension. Each line is interpreted as an expected parsing error, and the message in the file is compared to the parsed results. If they match, everything is ok, otherwise a test error is raised.\n\nFor example, if you have an 'examples/fileToBeParsed.txt' file, you can create a 'examples/fileToBeParsed.txt.errors' file containing the expected parse error messages.\n\nA tip to use this feature is to configure the plugin to shows the errors using **\u003cverbose\u003etrue\u003c/verbose\u003e** option. Then you can check the log output manually to see exact error message generated and copy/paste the error messages (only the parsed tree with no other message accessories) to the .errors file.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fantlr%2Fantlr4test-maven-plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fantlr%2Fantlr4test-maven-plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fantlr%2Fantlr4test-maven-plugin/lists"}