From 7c89ff4d355ca7563b56764cf012dada453d306b Mon Sep 17 00:00:00 2001 From: Daniel Scheffler Date: Wed, 22 Nov 2017 15:45:33 +0100 Subject: [PATCH] Added tests for plotting functions. --- tests/test_geoarray.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tests/test_geoarray.py b/tests/test_geoarray.py index 44ee2ed..8e1e28f 100644 --- a/tests/test_geoarray.py +++ b/tests/test_geoarray.py @@ -35,6 +35,7 @@ import unittest from unittest import TestLoader import matplotlib from typing import Iterable +from importlib import util # Imports regarding the created python module. from py_tools_ds.geo.vector import geometry @@ -510,8 +511,10 @@ class Test_GeoarrayFunctions(unittest.TestCase): # TODO: https://github.com/ketch/griddle/blob/master/tests/plot_tests.py self.testtiff.show() # self.testtiff.show(interactive=True) # only works if test is started with ipython. - # self.testtiff.show_map() - # self.testtiff.show_map_utm() # Function still under construction. + + if util.find_spec('mpl_toolkits.basemap'): + self.testtiff.show_map() + self.testtiff.show_map_utm() # Function still under construction. self.testtiff.show_histogram() # ----> TODO: Write tests for the remaining functions! -- GitLab