aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/util/util_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'util/util_test.go')
-rw-r--r--util/util_test.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/util/util_test.go b/util/util_test.go
index fd9b7b8..9c5881d 100644
--- a/util/util_test.go
+++ b/util/util_test.go
@@ -53,8 +53,9 @@ func testAnsiFilterWriter(t *testing.T, input string, expected string) {
t.Fatal("Error while writting input", err)
}
- if n != len(expected) {
- t.Errorf("Expected to write %d bytes but read %d\n", len(expected), n)
+ // NOTE: we expect the size of input to be written to indicate those bytes have been consumed by the writer
+ if n != len(input) {
+ t.Errorf("Expected to write %d bytes but wrote %d\n", len(input), n)
}
result := writer.String()