Skip to content

Commit 1f29260

Browse files
committed
Clarify ripper-variant test gating: env-gated locally, CI-only by default
Previous wording implied both parser backends ran on every test invocation. In reality the RipperRuby test class is gated by 'end if ENV["RDOC_USE_RIPPER_PARSER"]' at prism_ruby_test.rb:2503; local bundle exec rake exercises only prism. CI runs the ripper variant in a dedicated job. Note the env-var invocation an agent should use locally before claiming a parser change is verified.
1 parent f9571f9 commit 1f29260

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

AGENTS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ exe/
239239
- **Parsers:** Prism-based Ruby (default, `RDoc::Parser::PrismRuby`), legacy ripper-based Ruby (`RDoc::Parser::RipperRuby`, opt-in via `RDOC_USE_RIPPER_PARSER=1`), C, Markdown, RD
240240
- **Generators:** HTML/Aliki (default), HTML/Darkfish (deprecated), RI, POT (gettext), JSON, Markup
241241

242-
Both Ruby parsers must produce equivalent code-object trees. Parser tests are written once in the `RDocParserPrismTestCases` module (`test/rdoc/parser/prism_ruby_test.rb`); both `RDocParserPrismRubyTest` and `RDocParserRipperRubyWithPrismRubyTestCasesTest` include it, so each test runs against both backends. Add new parser tests there rather than to a parser-specific class.
242+
Both Ruby parsers must produce equivalent code-object trees. Parser tests are written once in the `RDocParserPrismTestCases` module (`test/rdoc/parser/prism_ruby_test.rb`) and included by `RDocParserPrismRubyTest` and `RDocParserRipperRubyWithPrismRubyTestCasesTest`. The ripper variant is gated on `RDOC_USE_RIPPER_PARSER` (so a local `bundle exec rake` exercises only prism); CI runs the ripper variant in a separate job (`.github/workflows/test.yml`). Add new parser tests to the mixin so both backends pick them up, and run the ripper variant locally with `RDOC_USE_RIPPER_PARSER=1 bundle exec rake` before declaring a parser change done.
243243

244244
### Code Object Model and Constant Aliases
245245

0 commit comments

Comments
 (0)