diff --git a/PlotInterface/maps.py b/PlotInterface/maps.py index 3fe9362c..53d4b3e1 100644 --- a/PlotInterface/maps.py +++ b/PlotInterface/maps.py @@ -196,8 +196,8 @@ def addGraticule(self, axes, mapobj): draw_labels=True) gl.xformatter = LONGITUDE_FORMATTER gl.yformatter = LATITUDE_FORMATTER - gl.xlabels_top = False - gl.ylabels_right = False + gl.top_labels = False + gl.right_labels = False def addCoastline(self, mapobj): """ diff --git a/tests/test_system.py b/tests/test_system.py index 157b6223..9c5b5447 100644 --- a/tests/test_system.py +++ b/tests/test_system.py @@ -38,7 +38,7 @@ def setUp(self): self.addCleanup(Utilities.config.reset) self.tmpdir = tempfile.TemporaryDirectory() - self.addCleanup(self.tmpdir.cleanup) + #self.addCleanup(self.tmpdir.cleanup) self.configFile = os.path.join( Utilities.pathLocator.getRootDirectory(), @@ -48,6 +48,7 @@ def setUp(self): config = Utilities.config.ConfigParser() config.read(self.configFile) config['Output']['Path'] = self.tmpdir.name + config['WindfieldInterface']['PlotOutput'] = 'True' @decimate(100) def test_scenario(self): @@ -71,5 +72,8 @@ def test_scenario(self): self.assertGreater(white.sum() / pixels, 0.2) # substantial space self.assertGreater(color.sum() / pixels, 0.05) # significant color + from time import sleep + sleep(1) + if __name__ == '__main__': unittest.main() diff --git a/wind/writer.py b/wind/writer.py index d06b9a36..405d6888 100644 --- a/wind/writer.py +++ b/wind/writer.py @@ -111,7 +111,7 @@ def __call__(self, time, gust, Ux, Uy, P, lon, lat): t = len(self.time) if not t: - self.time.units = "days since " + time.strftime() + self.time.units = "days since " + time.strftime("%Y-%m-%d %H:%M") # convert window extent to slice indices origin = np.rint(self.affine * (lon[0], lat[0])).astype(int)