Skip to content

Commit

Permalink
test _read_header
Browse files Browse the repository at this point in the history
  • Loading branch information
jguerber committed Sep 3, 2022
1 parent e42b901 commit 55f1b82
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,18 @@ using Test
); detecttype = true)
end

@testset "_read_header" begin
a = ASCIIrasters._read_header("../example/cellsize.asc")
b = ASCIIrasters._read_header("../example/cellsizeanddx.asc")
c = ASCIIrasters._read_header("../example/nonodata.asc")
@test length(a) == 9
@test length(b) == 9
@test length(c) == 9
@test !haskey(b, "cellsize")
@test !haskey(a, "cellsize")
@test c["datatype"] == Any
end

# cleanup
rm("./test.asc")
rm("./test2.asc")
Expand Down

0 comments on commit 55f1b82

Please sign in to comment.