MCPcopy Create free account
hub / github.com/awslabs/aws-lambda-cpp / CaptureStream

Function CaptureStream

tests/gtest/gtest-all.cc:10870–10877  ·  view source on GitHub ↗

Starts capturing an output stream (stdout/stderr).

Source from the content-addressed store, hash-verified

10868
10869// Starts capturing an output stream (stdout/stderr).
10870static void CaptureStream(int fd, const char* stream_name,
10871 CapturedStream** stream) {
10872 if (*stream != nullptr) {
10873 GTEST_LOG_(FATAL) << "Only one " << stream_name
10874 << " capturer can exist at a time.";
10875 }
10876 *stream = new CapturedStream(fd);
10877}
10878
10879// Stops capturing the output stream and returns the captured string.
10880static std::string GetCapturedStream(CapturedStream** captured_stream) {

Callers 2

CaptureStdoutFunction · 0.85
CaptureStderrFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected