Skip to content

Commit

Permalink
Test is_utf8_start is_utf8_continuation deprecations
Browse files Browse the repository at this point in the history
  • Loading branch information
ScottPJones committed Jul 30, 2015
1 parent e493348 commit 34b1eae
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions test/deprecated.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,19 @@ if (Base.JLOptions()).depwarn > 1
@test_throws ErrorException Base.utf16_is_lead(0xd800)
@test_throws ErrorException Base.utf16_is_trail(0xdc00)
@test_throws ErrorException Base.utf16_get_supplementary(0xd800, 0xdc00)
@test_throws ErrorException Base.is_utf8_start(0x40)
@test_throws ErrorException Base.is_utf8_continuation(0x90)
else
olderr = STDERR
try
rd, wr = redirect_stderr()
@test Base.utf16_is_surrogate(0xdc00) == true
@test Base.utf16_is_lead(0xd800) == true
@test Base.utf16_is_trail(0xdc00) == true
@test Base.utf16_is_surrogate(0xdc00)
@test Base.utf16_is_lead(0xd800)
@test Base.utf16_is_trail(0xdc00)
@test Base.utf16_get_supplementary(0xd800, 0xdc00) == 0x10000
@test Base.is_utf8_start(0x40)
@test Base.is_utf8_continuation(0x90)
finally
redirect_stderr(olderr)
end
end
end

0 comments on commit 34b1eae

Please sign in to comment.