Skip to content

Commit 1d6519d

Browse files
committed
Overload two arg show for OrderedDictWrapper
1 parent 3897572 commit 1d6519d

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

src/utils.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ function Base.show(io::IO, m::MIME"text/plain", odw::OrderedDictWrapper)
8080
_printstyled(io, "Parent Catalog: ", title(odw.data))
8181
end
8282

83+
Base.show(io::IO, odw::OrderedDictWrapper) = show(io, MIME("text/plain"), odw)
8384
odwtype(x) = string(x) * " of "
8485
Base.length(odw::OrderedDictWrapper) = length(collect(keys(odw)))
8586

test/runtests.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ end
4444
item = subcat1.items["LC08_L1TP_152038_20200611_20200611_01_RT"]
4545
itemint = subcat1.items[1]
4646
@test item == itemint
47+
@test_throws BoundsError subcat1.items[2]
4748
testshow(item,"box")
4849
testshow(item, "LC08_L1TP_152038_20200611_20200611_01_RT")
4950

0 commit comments

Comments
 (0)