Feature Request: Create tests for syntax highlighter YAML files

オープン
#3,903 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 3 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
25/100
issue の種類
機能追加
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
go
領域
testing-qa

調査の方向性

まず runtime/syntax/markdown.yaml と、ネストされた Markdown 書式に対する既存の構文解析動作を調べます。提案されているアプローチを CommonMark の spec.json の例と比較し、その後、代表的な構文ケースと、結果を期待される解析済みの要素と照合できる検証メカニズムを定義します。

索引モデルが issue の本文から書いたものです。

説明

When creating or updating syntax files for languages that have complex syntax rules (such as nested formatting types in Markdown, $\LaTeX$, or AsciiDoc), it may be helpful to have syntax examples and their correct parsings to compare changes against.

For example, I am working on updating the Markdown syntax file to fix some style nesting bugs, such as the following bug that incorrectly renders bold text inside an italicized sentence:

The string `*This italicized sentence has **bold text** inside.*` which has been rendered partially incorrectly by micro's syntax provider

In this case, once a solution has been found, it would be quick to test a few strings of italicized and bold text and verify that a fix works. However, when combined with other rules, this case would become more time-consuming to manually verify that fixes have been made and existing cases have not been broken.

Would it be possible to implement some sort of parsing validation system to ensure code is broken down into the correct "pieces"?

One related example that comes to mind is CommonMark's spec tests that include pairs of Markdown source strings and their proper HTML renderings. I'm not sure how Micro handles parsed code or if a system like this would be possible, but I wanted to bring up the idea in case others may find it useful as well.

主要言語
Go
スター
29.8k
フォーク
1.4k
平均マージ
1日 12時間
マージ済み PR(30日)
2

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

micro-editor/micro のほかの issue

micro-editor/micro の issue をすべて見る

似ている issue

Go の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。