mirror of
https://github.com/catchorg/Catch2.git
synced 2025-08-02 05:15:39 +02:00
Add %stderr and %stdout as recognized magic stream names
This commit is contained in:
@@ -17,3 +17,12 @@ TEST_CASE( "Cout stream properly declares it writes to stdout", "[streams]" ) {
|
||||
TEST_CASE( "Empty stream name opens cout stream", "[streams]" ) {
|
||||
REQUIRE( Catch::makeStream( "" )->isStdout() );
|
||||
}
|
||||
|
||||
TEST_CASE( "stdout and stderr streams have %-starting name", "[streams]" ) {
|
||||
REQUIRE( Catch::makeStream( "%stderr" )->isStdout() );
|
||||
REQUIRE( Catch::makeStream( "%stdout" )->isStdout() );
|
||||
}
|
||||
|
||||
TEST_CASE( "request an unknown %-starting stream fails", "[streams]" ) {
|
||||
REQUIRE_THROWS( Catch::makeStream( "%somestream" ) );
|
||||
}
|
||||
|
Reference in New Issue
Block a user