TestStdoutStream class

A Stdout mock object.

Implemented types

Constructors

TestStdoutStream()

Properties

done Future
A future that will complete when the consumer closes, or when an error occurs.
no setterinherited
encoding Encoding
The Encoding used when writing strings.
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
hasTerminal bool
Whether there is a terminal attached to stdout.
no setterinherited
lineTerminator String
Line ending appended by writeln, and replacing "\n" in some methods.
getter/setter pairinherited
nonBlocking IOSink
A non-blocking IOSink for the same output.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
supportsAnsiEscapes bool
Whether connected to a terminal that supports ANSI escape sequences.
no setterinherited
terminalColumns int
The number of columns of the terminal.
no setterinherited
terminalLines int
The number of lines of the terminal.
no setterinherited
writes List<List<int>>
final

Methods

add(List<int> bytes) → void
Adds byte data to the target consumer, ignoring encoding.
addError(Object error, [StackTrace? stackTrace]) → void
Passes the error to the target consumer as an error event.
inherited
addStream(Stream<List<int>> stream) Future
Adds all elements of the given stream.
inherited
close() Future
Close the target consumer.
inherited
flush() Future
Returns a Future that completes once all buffered data is accepted by the underlying StreamConsumer.
inherited
noSuchMethod(Invocation invocation) → void
Invoked when a nonexistent method or property is accessed.
override
toString() String
A string representation of this object.
inherited
write(Object? object) → void
Converts object to a String by invoking Object.toString and adds the encoding of the result to the target consumer.
inherited
writeAll(Iterable objects, [String sep = ""]) → void
Iterates over the given objects and writes them in sequence.
inherited
writeCharCode(int charCode) → void
Writes the character of charCode.
inherited
writeln([Object? object = ""]) → void
Converts object to a String by invoking Object.toString and writes the result to this, followed by a newline.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited