From 1f87ccf0ae8f7ef422fc93415e507066ba5e2273 Mon Sep 17 00:00:00 2001 From: Katharine Hyatt Date: Sat, 19 Oct 2024 15:03:32 -0400 Subject: [PATCH] Test for showing AnnotatedIOBuffer --- test/strings/annotated.jl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/strings/annotated.jl b/test/strings/annotated.jl index 85acab74abf7b..9418ff26ef43a 100644 --- a/test/strings/annotated.jl +++ b/test/strings/annotated.jl @@ -244,4 +244,8 @@ end @test write(wrapio, Base.AnnotatedChar('a', [(:y, 2)])) == 1 @test read(seekstart(aio), Base.AnnotatedString) == Base.AnnotatedString("heya", [(1:3, :x, 1), (4:4, :y, 2)]) + # show-ing an AnnotatedIOBuffer + aio = Base.AnnotatedIOBuffer() + write(aio, Base.AnnotatedString("hello", [(1:5, :tag, 1)])) + @test sprint(show, aio) == "Base.AnnotatedIOBuffer(5 bytes, 1 annotation)" end