Class ConsoleOutput

Inheritance Relationships

Base Type

Class Documentation

class ConsoleOutput : public mu::tiny::test::Output
[source]

Writes test output to stdout using printf.

This is the default Output used by CommandLineRunner. It relies on the replaceable Output::stdout_, Output::fopen_, Output::fputs_, and Output::fclose_ function pointers, allowing I/O to be redirected in tests.

Public Functions

explicit ConsoleOutput() = default
[source]
~ConsoleOutput() override = default
[source]
virtual void print_buffer(const char *s) override

Write s to the console via the fputs_ function pointer.

Parameters:

s – Null-terminated string to write.

virtual void flush() override
[source]

Flush all pending output to the console.

ConsoleOutput(const ConsoleOutput&) = delete
ConsoleOutput &operator=(const ConsoleOutput&) = delete