diff --git a/packages/python/plotly/plotly/tests/test_core/test_validators/__init__.py b/packages/python/plotly/plotly/tests/test_core/test_validators/__init__.py new file mode 100644 index 00000000000..e1565c83f71 --- /dev/null +++ b/packages/python/plotly/plotly/tests/test_core/test_validators/__init__.py @@ -0,0 +1,5 @@ +import warnings + + +def setup_package(): + warnings.filterwarnings("ignore") diff --git a/packages/python/plotly/plotly/tests/test_core/test_validators/test_validators.py b/packages/python/plotly/plotly/tests/test_core/test_validators/test_validators.py new file mode 100644 index 00000000000..855a47a4d9d --- /dev/null +++ b/packages/python/plotly/plotly/tests/test_core/test_validators/test_validators.py @@ -0,0 +1,11 @@ + +from __future__ import absolute_import + +from unittest import TestCase +import plotly.graph_objs as go + + +class TestValidators(TestCase): + def test_layout_shape_line_dash_validator(self): + # regression from issue #3375 + go.layout.shape.Line(color='black', width=2, dash='5px,3px,3px,2px') diff --git a/packages/python/plotly/plotly/validators/layout/shape/line/_dash.py b/packages/python/plotly/plotly/validators/layout/shape/line/_dash.py index 4b42018c816..77766d5540b 100644 --- a/packages/python/plotly/plotly/validators/layout/shape/line/_dash.py +++ b/packages/python/plotly/plotly/validators/layout/shape/line/_dash.py @@ -1,7 +1,7 @@ import _plotly_utils.basevalidators -class DashValidator(_plotly_utils.basevalidators.StringValidator): +class DashValidator(_plotly_utils.basevalidators.DashValidator): def __init__(self, plotly_name="dash", parent_name="layout.shape.line", **kwargs): super(DashValidator, self).__init__( plotly_name=plotly_name,