diff --git a/plotly/tests/test_optional/test_ipython/test_widgets.py b/plotly/tests/test_optional/test_ipython/test_widgets.py new file mode 100644 index 00000000000..6d54403065b --- /dev/null +++ b/plotly/tests/test_optional/test_ipython/test_widgets.py @@ -0,0 +1,9 @@ +from unittest import TestCase + +from plotly.widgets import GraphWidget + + +class TestWidgets(TestCase): + + def test_instantiate_graph_widget(self): + widget = GraphWidget diff --git a/plotly/version.py b/plotly/version.py index 4574cc8974f..f3df7f04b75 100644 --- a/plotly/version.py +++ b/plotly/version.py @@ -1 +1 @@ -__version__ = '1.6.3' +__version__ = '1.6.5' diff --git a/plotly/widgets/graph_widget.py b/plotly/widgets/graph_widget.py index 8953924fcf0..1f7666138ac 100644 --- a/plotly/widgets/graph_widget.py +++ b/plotly/widgets/graph_widget.py @@ -14,10 +14,8 @@ # Load JS widget code # No officially recommended way to do this in any other way # http://mail.scipy.org/pipermail/ipython-dev/2014-April/013835.html -directory = os.path.dirname(os.path.realpath(__file__)) -js_widget_file = os.path.join(directory, 'graphWidget.js') js_widget_code = resource_string('plotly', - 'widgets/graphWidgets.js').decode('utf-8') + 'widgets/graphWidget.js').decode('utf-8') display(Javascript(js_widget_code))