Skip to content

Commit

Permalink
Update for new StrAPI
Browse files Browse the repository at this point in the history
  • Loading branch information
ScottPJones committed Oct 21, 2018
1 parent d9f0506 commit 9c7c783
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion REQUIRE
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
julia 0.6 2-
ModuleInterfaceTools 0.1.7
StrAPI 0.1.8
StrAPI 0.1.9
2 changes: 1 addition & 1 deletion src/charsets.jl
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ for lst in cse_info
nam = lst[1]
csnam = symstr(nam, "CharSet")
@eval const $csnam = CharSet{$(quotesym(nam))}
@eval show(io::IO, ::Type{$csnam}) = print(IO, string(csnam))
@eval show(io::IO, ::Type{$csnam}) = print(io, $(string(csnam)))
@eval push!(charset_types, $csnam)
@eval @api $(String(nam)[1] == '_' ? :develop : :public) $csnam
end
Expand Down
7 changes: 7 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ using ModuleInterfaceTools
@testset "CharSet" begin
for CS in charset_types
@test CS <: CharSet
nam = sprint(show, CS)
@test endswith(nam, "CharSet") || startswith(nam, "CharSet{:")
end
end

Expand All @@ -23,3 +25,8 @@ end
@test encoding(CS) <: Encoding
end
end

@testset "show charsets" begin
for CS in charset_types
end
end

0 comments on commit 9c7c783

Please sign in to comment.