summaryrefslogtreecommitdiff
path: root/spec/syntax_suggest/unit/explain_syntax_spec.rb
AgeCommit message (Collapse)Author
2026-04-07Fix sync for `syntax_suggest`Earlopain
It is a bit special in that is uses `spec` for tests. Since https://github.com/ruby/ruby/pull/15015 those did not get synced anymore. This fixes the mapping to what is was before and pulls in missing changes
2023-12-05[ruby/syntax_suggest] Change assertion to not rely on exact text from prismSchneems
The original ripper test was very stable as the output didn't change. Prism is under active development and changing their output shouldn't cause a failure to the ruby/ruby test suite like https://github.com/ruby/ruby/actions/runs/7104601478/job/19339940315. This commit moves from checking exact output to asserting that the string we get back is not empty. This should give the same level of confidence that some error message was caught, and is less brittle. https://github.com/ruby/syntax_suggest/commit/4b6abb763e
2023-12-05[ruby/syntax_suggest] Initial support for the prism parserSchneems
Prism will be the parser in Ruby 3.3. We need to support 3.0+ so we will have to "dual boot" both parsers. Todo: - LexAll to support Prism lex output - Add tests that exercise both Ripper and prism codepaths on CI - Handle https://github.com/ruby/prism/issues/1972 in `ripper_errors.rb` - Update docs to not mention Ripper explicitly - Consider different/cleaner APIs for separating out Ripper and Prism https://github.com/ruby/syntax_suggest/commit/a7d6991cc4
2022-08-26Import spec examples from ruby/syntax_suggestHiroshi SHIBATA
Notes: Merged: https://github.com/ruby/ruby/pull/6287