mirror of
https://github.com/catchorg/Catch2.git
synced 2025-08-02 05:15:39 +02:00
Add IStream::isStdOut
This commit is contained in:
19
tests/SelfTest/IntrospectiveTests/Stream.tests.cpp
Normal file
19
tests/SelfTest/IntrospectiveTests/Stream.tests.cpp
Normal file
@@ -0,0 +1,19 @@
|
||||
|
||||
// Copyright Catch2 Authors
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// https://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// SPDX-License-Identifier: BSL-1.0
|
||||
|
||||
#include <catch2/catch_test_macros.hpp>
|
||||
|
||||
#include <catch2/internal/catch_stream.hpp>
|
||||
|
||||
TEST_CASE( "Cout stream properly declares it writes to stdout", "[streams]" ) {
|
||||
REQUIRE( Catch::makeStream( "-" )->isStdout() );
|
||||
}
|
||||
|
||||
TEST_CASE( "Empty stream name opens cout stream", "[streams]" ) {
|
||||
REQUIRE( Catch::makeStream( "" )->isStdout() );
|
||||
}
|
Reference in New Issue
Block a user