From 33beca15daae867c54e0552f5795213c4bfafc6b Mon Sep 17 00:00:00 2001 From: NatureFreshMilk Date: Tue, 1 Oct 2019 08:13:55 +0200 Subject: [PATCH] vent fix --- tilerenderer/renderer_benchmark_test.go | 5 +---- tilerenderer/renderer_test.go | 19 ++----------------- 2 files changed, 3 insertions(+), 21 deletions(-) diff --git a/tilerenderer/renderer_benchmark_test.go b/tilerenderer/renderer_benchmark_test.go index 6670f95..fbcac80 100644 --- a/tilerenderer/renderer_benchmark_test.go +++ b/tilerenderer/renderer_benchmark_test.go @@ -72,14 +72,11 @@ func BenchmarkTileRender(b *testing.B) { for n := 0; n < b.N; n++ { - data, err := tr.Render(coord) + err := tr.Render(coord) if err != nil { panic(err) } - if data == nil { - panic("no data") - } } } diff --git a/tilerenderer/renderer_test.go b/tilerenderer/renderer_test.go index 4dc8ee4..b6f43d4 100644 --- a/tilerenderer/renderer_test.go +++ b/tilerenderer/renderer_test.go @@ -1,7 +1,6 @@ package tilerenderer import ( - "bytes" "io/ioutil" "mapserver/colormapping" "mapserver/coords" @@ -69,30 +68,16 @@ func TestTileRender(t *testing.T) { } coord := coords.NewTileCoords(0, 0, 12, 0) - data, err := tr.Render(coord) + err = tr.Render(coord) if err != nil { panic(err) } - if data == nil { - panic("no data") - } - - f, _ := os.Create("../test-output/0_0_12.png") - bytes.NewReader(data).WriteTo(f) - coord1 := coord.GetZoomedOutTile() - data, err = tr.Render(coord1) + err = tr.Render(coord1) if err != nil { panic(err) } - if data == nil { - panic("no data") - } - - f, _ = os.Create("../test-output/0_0_13.png") - bytes.NewReader(data).WriteTo(f) - }