Skip to content

Commit

Permalink
hotfix
Browse files Browse the repository at this point in the history
  • Loading branch information
giocaizzi committed Dec 26, 2021
1 parent 31d3cff commit d64c8b4
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ __pycache__
*.egg-info
temp
docsrc/build
temp
2 changes: 1 addition & 1 deletion mplStrater/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import rio_color.operations as rio
from rio_color.colorspace import ColorSpace as cs
from rio_color.colorspace import convert_arr
from mplStrater.strata import *
from mplStrater.strata import Column
import matplotlib.patheffects as pe
from matplotlib.gridspec import GridSpec

Expand Down
2 changes: 1 addition & 1 deletion mplStrater/strata.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def __init__(self,d=None,colors=None,hatches=None):
elif hatches is not None and colors is None:
self.hatches=hatches
else:
ValueError("This symbology profile is not implemented.")
raise ValueError("This symbology profile is not implemented.")

class Legend:
"""
Expand Down
10 changes: 4 additions & 6 deletions tests/test_strata.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import unittest
from matplotlib.colors import ListedColormap
from numpy import less_equal
from mplStrater.strata import *
from mplStrater.strata import Symbology,Legend,Column

class TestSymbology(unittest.TestCase):

Expand All @@ -22,15 +22,13 @@ def test_hatches(self):

def test_error(self):
#test error input
d={}
hatches=["","xxxxxxxxx",""]
colors=["green","white","blue"]
self.assertRaises(
ValueError,
Symbology(d={},colors=colors,hatches=hatches)
)



Symbology,
d,colors=colors,hatches=hatches)

class TestLegend(unittest.TestCase):

Expand Down

0 comments on commit d64c8b4

Please sign in to comment.