Skip to content
This repository has been archived by the owner on Apr 23, 2020. It is now read-only.

Commit

Permalink
[FrontendTests] Try again to make test not write an output file
Browse files Browse the repository at this point in the history
Setting the output stream to nulls seems to work.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@375491 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
d0k committed Oct 22, 2019
1 parent 3f4b391 commit 65acf43
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions unittests/Frontend/OutputStreamTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ TEST(FrontendOutputTests, TestVerboseOutputStreamShared) {
std::string VerboseBuffer;
raw_string_ostream VerboseStream(VerboseBuffer);

Compiler.setOutputStream(std::make_unique<raw_null_ostream>());
Compiler.setInvocation(std::move(Invocation));
IntrusiveRefCntPtr<DiagnosticOptions> DiagOpts = new DiagnosticOptions();
Compiler.createDiagnostics(
Expand Down Expand Up @@ -86,6 +87,7 @@ TEST(FrontendOutputTests, TestVerboseOutputStreamOwned) {
std::unique_ptr<raw_ostream> VerboseStream =
std::make_unique<raw_string_ostream>(VerboseBuffer);

Compiler.setOutputStream(std::make_unique<raw_null_ostream>());
Compiler.setInvocation(std::move(Invocation));
IntrusiveRefCntPtr<DiagnosticOptions> DiagOpts = new DiagnosticOptions();
Compiler.createDiagnostics(
Expand Down

0 comments on commit 65acf43

Please sign in to comment.