Skip to content

Support VSCode C++TestMate extension - #716

Open
minoru-nagasawa wants to merge 5 commits into
srz-zumix:masterfrom
minoru-nagasawa:feature/vscode-cpp-testmate-support
Open

Support VSCode C++TestMate extension#716
minoru-nagasawa wants to merge 5 commits into
srz-zumix:masterfrom
minoru-nagasawa:feature/vscode-cpp-testmate-support

Conversation

@minoru-nagasawa

Copy link
Copy Markdown

VSCodeの拡張機能C++TestMateでIUTESTのテストを検出できるように修正しました。
C++TestMateが認識するようにGoogleTestと出力形式を一致させています。

対象拡張機能:
https://marketplace.visualstudio.com/items?itemName=matepek.vscode-catch2-test-adapter

変更内容

--helpの出力メッセージを調整

C++TestMateは以下の正規表現に一致するかどうかでGoogleTestを判定しているため、IUTEST側の--helpを修正しました。
This program contains tests written using .*--(\w+)list_tests.*List the names of all tests instead of running them

--iutest_list_testsの出力形式を調整(suite名の末尾に . を追加)

C++TestMateが想定する形式に合わせるため、Test Suite名の後にピリオドを追加しました。

--iutest_list_tests + --iutest_output=xmlに対応

テスト検出に必要なため、list_tests実行時に XML出力できるよう対応しました。

実行時間表示のフォーマットを調整("ms"の前にスペースを追加)

C++TestMateの解析形式に合わせるため、XXms → XX ms となるようにしました。

結果

これにより、C++TestMate上でIUTESTのテストが一覧表示され、GUIから個別実行できるようになります。

image

ご確認よろしくお願いします。

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for contributing and submitting your first pull request for this project

@srz-zumix

Copy link
Copy Markdown
Owner

PR ありがとうございます。最近全くメンテナンスできておらず、レビューにお時間いただくことになると思います。
申し訳ありません 🙇

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants