Skip to content
Snippets Groups Projects
Commit 4bff6602 authored by nugget's avatar nugget
Browse files

Fix TagPlot tests because positional argument was at wrong position.

parent ef4637cf
No related branches found
No related tags found
3 merge requests!12v.0.1 for alpha release,!6Implement basic functionality of publish.,!4Fix TagPlot tests because positional argument was at wrong position.
Image diff could not be displayed: it is too large. Options to address this: view the blob.
Image diff could not be displayed: it is too large. Options to address this: view the blob.
......@@ -66,5 +66,5 @@ for i, figure in enumerate(figs):
figure.savefig(name)
# %% Publish
publish('fcn_help', '/home/chief/Dokumente/fst/plotid_python/data',
'/home/chief/Dokumente/fst/plotid_python/Test1.tiff', 'individual')
#publish('fcn_help', '/home/chief/Dokumente/fst/plotid_python/data',
# '/home/chief/Dokumente/fst/plotid_python/Test1.tiff', 'individual')
......@@ -42,31 +42,31 @@ class TestTagPlot(unittest.TestCase):
with self.assertRaises(TypeError):
TagPlot('fig', ProjectID, plot_engine, method)
with self.assertRaises(TypeError):
TagPlot(figs=fig1, prefix=ProjectID, engine=plot_engine)
TagPlot(fig1, plot_engine, prefix=ProjectID)
def test_prefix(self):
with self.assertRaises(TypeError):
TagPlot(fig, 3, plot_engine, method)
TagPlot(fig, plot_engine, 3, method)
def test_plotengine(self):
with self.assertRaises(ValueError):
TagPlot(fig, ProjectID, 1, method)
TagPlot(fig, 1, ProjectID, method)
with self.assertRaises(ValueError):
TagPlot(fig, ProjectID, 'xyz', method)
TagPlot(fig, 'xyz', ProjectID, method)
def test_idmethod(self):
with self.assertRaises(TypeError):
TagPlot(fig, ProjectID, plot_engine, method='(0,1)')
TagPlot(fig, plot_engine, ProjectID, method='(0,1)')
with self.assertRaises(TypeError):
TagPlot(fig, ProjectID, plot_engine, method='h')
TagPlot(fig, plot_engine, ProjectID, method='h')
with self.assertRaises(TypeError):
TagPlot(fig, ProjectID, plot_engine, method='[0,1]')
TagPlot(fig, plot_engine, ProjectID, method='[0,1]')
def test_location(self):
with self.assertRaises(TypeError):
TagPlot(fig, ProjectID, plot_engine, method, location=1)
TagPlot(fig, plot_engine, ProjectID, method, location=1)
with self.assertWarns(Warning):
TagPlot(fig, ProjectID, plot_engine, method, location='up')
TagPlot(fig, plot_engine, ProjectID, method, location='up')
if __name__ == '__main__':
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment