[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-23 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG352a2e671625: [clang][tooling] NFC: Refactor command-line diagnostic tests (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGE

[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-22 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith accepted this revision. dexonsmith added a comment. This revision is now accepted and ready to land. LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110160/new/ https://reviews.llvm.org/D110160 __

[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-22 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 374383. jansvoboda11 added a comment. Use empty files and `-E` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110160/new/ https://reviews.llvm.org/D110160 Files: clang/unittests/Tooling/ToolingTest.cpp

[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-22 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. I think we need a warning option to be able to suppress it (or conditionally promote to an error). Comment at: clang/unittests/Tooling/ToolingTest.cpp:238-245 Args.push_back("tool-executable"); - Args.push_back("-target"); - // Invalid argume

[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-22 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 374382. jansvoboda11 added a comment. Use flags not specific to Darwin Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110160/new/ https://reviews.llvm.org/D110160 Files: clang/unittests/Tooling/ToolingTe

[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-21 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added a comment. Stepping back, maybe it'd be better to use a more generic option that is unlikely to have special behaviour in any target (or downstream). Best one I could find is triggering `err_drv_unknown_language` with `-x this-is-an-unknown-language`. WDYT?

[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-21 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: clang/unittests/Tooling/ToolingTest.cpp:238-245 Args.push_back("tool-executable"); - Args.push_back("-target"); - // Invalid argument that by default results in an error diagnostic: - Args.push_back("i386-apple-ios14.0-simulator

[PATCH] D110160: [clang][tooling] NFC: Refactor command-line diagnostic tests

2021-09-21 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch uses a different command-line arguments to test `clang::tooling::ToolInvocatio