Add geojson exporter

This commit is contained in:
Guille Gutierrez 2023-10-24 08:01:57 +02:00
parent 6ee1466b8e
commit b711bceb7b

View File

@ -7,6 +7,7 @@ Code contributors: Pilar Monsalvete Alvarez de Uribarri pilar.monsalvete@concord
"""
import json
import logging.handlers
import os
from pathlib import Path
from unittest import TestCase
from hub.imports.geometry_factory import GeometryFactory
@ -109,6 +110,7 @@ class TestExports(TestCase):
self.assertEqual('Polygon', geometry['type'], 'Wrong geometry type')
self.assertEqual(1, len(geometry['coordinates']), 'Wrong polygon structure')
self.assertEqual(11, len(geometry['coordinates'][0]), 'Wrong number of vertices')
os.unlink(geojson_file) # todo: this test need to cover a multipolygon example too
def test_energy_ade_export(self):
"""