Permalink
Browse files

indentation

  • Loading branch information...
yeesian authored and visr committed Nov 4, 2018
1 parent c669d36 commit c6d2f47d3541de0dc85dca971c48c8fa348b8faa
Showing with 17 additions and 17 deletions.
  1. +17 −17 test/test_gdal_tutorials.jl
@@ -101,25 +101,25 @@ AG.registerdrivers() do
end

@testset "Approach 1" begin
pointshapefile = "tmp/point_out"
AG.create("$pointshapefile.shp", "ESRI Shapefile") do dataset
layer = AG.createlayer(dataset, "point_out", geom=GDAL.wkbPoint)
AG.createfielddefn("Name", GDAL.OFTString) do fielddefn
AG.setwidth!(fielddefn, 32)
AG.createfield!(layer, fielddefn, true)
pointshapefile = "tmp/point_out"
AG.create("$pointshapefile.shp", "ESRI Shapefile") do dataset
layer = AG.createlayer(dataset, "point_out", geom=GDAL.wkbPoint)
AG.createfielddefn("Name", GDAL.OFTString) do fielddefn
AG.setwidth!(fielddefn, 32)
AG.createfield!(layer, fielddefn, true)
end
featuredefn = AG.getlayerdefn(layer)
@test AG.getname(featuredefn) == "point_out"
AG.createfeature(featuredefn) do feature
AG.setfield!(feature, AG.getfieldindex(feature, "Name"), "myname")
AG.setgeomdirectly!(feature, AG.unsafe_createpoint(100.123, 0.123))
AG.createfeature!(layer, feature)
end
end
featuredefn = AG.getlayerdefn(layer)
@test AG.getname(featuredefn) == "point_out"
AG.createfeature(featuredefn) do feature
AG.setfield!(feature, AG.getfieldindex(feature, "Name"), "myname")
AG.setgeomdirectly!(feature, AG.unsafe_createpoint(100.123, 0.123))
AG.createfeature!(layer, feature)
end
end

rm("$pointshapefile.dbf")
rm("$pointshapefile.shp")
rm("$pointshapefile.shx")
rm("$pointshapefile.dbf")
rm("$pointshapefile.shp")
rm("$pointshapefile.shx")
end
end
end

0 comments on commit c6d2f47

Please sign in to comment.