Refactor tests to use `checkPackage` directly
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 48/100
- issue の種類
- リファクタリング
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- dart
- 領域
- testing-qa
調査の方向性
executable_test.dart から始め、#138 で参照されている workspace のテストと比較します。現在テストがどのようにツールを呼び出し、stdout、stderr、終了コードを確認しているかを追跡し、その後 checkPackage() と package:test のストリーム matcher を確認します。実行可能ファイルのテストが直接のエントリーポイントを使用し、これらの assertions を維持し、workspace のテストに近い実行時間を達成すれば完了です。
索引モデルが issue の本文から書いたものです。
説明
The workspace tests (see #138) run 11 tests in just 1 second, or about 0.1 sec/test. The existing executable_test.dart tests run 25 tests in 1:40, or about 4 sec/test. That's not prohibitively long, but maybe it can be improved.
Both tests generate directories and files to disk in the same way and run the tool on those files. The main difference is that instead of calling dart run dependency_validator and checking the output, the workspace tests call checkPackage() directly and don't spawn any new processes.
The original tests do more than just check the return value though. They also check the stdout, stderr, and exit code, so they use Process.start. They can probably be rewritten to use checkPackage() directly with a custom logger, and use stream matchers from package:test instead of checking the entire process output.
If this results in tests that run similarly to the workspace tests, that could mean the 25 tests will be complete in about 2.5 seconds -- an over 95% speedup.
- 主要言語
- Dart
- スター
- 66
- フォーク
- 26
- 平均マージ
- 37分
- マージ済み PR(30日)
- 1
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Workiva/dependency_validator のほかの issue
-
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
Workiva/dependency_validator#176 · リアクション 2 件 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 30/100
Workiva/dependency_validator#167 · コメント 2 件 ·
-
Support Doc Importsオープン
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
Workiva/dependency_validator#153 · コメント 1 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 48/100
Workiva/dependency_validator#141 · リアクション 1 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
Workiva/dependency_validator#134 · コメント 1 件 ·
Workiva/dependency_validator の issue をすべて見る
似ている issue
-
good first issue spells
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
type:bug
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 2 日以内に返信
-
Standalone dash flashes as its own RSVP step (e.g. Russian dialogue)対応中かも @bezig01 が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
daniel-pimenta-cc/ledor#53 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
メンテナーはふだん 2 日以内に返信