Skip to content

Commit

Permalink
Try to fix test on 0.6
Browse files Browse the repository at this point in the history
  • Loading branch information
ararslan committed Feb 3, 2018
1 parent 5be9dd8 commit 4e5d84f
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1307,7 +1307,14 @@ end

# 0.7.0-DEV.3585
let buf = IOBuffer()
printstyled(IOContext(buf, :color=>true), "foo", color=:red)
if VERSION < v"0.7.0-DEV.3077"
col = Base.have_color
eval(Base, :(have_color = true))
printstyled(buf, "foo", color=:red)
eval(Base, :(have_color = $col))
else
printstyled(IOContext(buf, :color=>true), "foo", color=:red)
end
@test startswith(String(take!(buf)), Base.text_colors[:red])
end

Expand Down

0 comments on commit 4e5d84f

Please sign in to comment.