Skip to content

Commit c5a5e9f

Browse files
committed
TestCase.assertRaises not a context manager until Python 2.7.
1 parent 587affd commit c5a5e9f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

plotly/tests/test_core/test_plotly/test_plot.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ class TestPlot(TestCase):
6262

6363
def test_plot_empty_data(self):
6464
py.sign_in('PlotlyImageTest', '786r5mecv0')
65-
with self.assertRaises(PlotlyEmptyDataError):
66-
py.plot([], filename='plot_invalid')
65+
self.assertRaises(PlotlyEmptyDataError, py.plot, [],
66+
filename='plot_invalid')
6767

6868

6969
def test_bar():

0 commit comments

Comments
 (0)