File tree Expand file tree Collapse file tree 3 files changed +13
-6
lines changed
plotly/tests/test_graph_objs Expand file tree Collapse file tree 3 files changed +13
-6
lines changed Original file line number Diff line number Diff line change 7
7
"""
8
8
from nose .tools import raises
9
9
from ...graph_objs .graph_objs import *
10
- from ...exceptions import (PlotlyDictKeyError , PlotlyDictValueError ,
10
+ from ...exceptions import (PlotlyError ,
11
+ PlotlyDictKeyError ,
12
+ PlotlyDictValueError ,
11
13
PlotlyDataTypeError , PlotlyListEntryError )
12
14
13
15
@@ -20,8 +22,9 @@ def test_trivial():
20
22
assert Annotations () == list ()
21
23
22
24
23
- def test_weird_instantiation (): # Python allows this...
24
- assert Annotations ({}) == list ({})
25
+ @raises (PlotlyError )
26
+ def test_weird_instantiation (): # Python allows this, but nonsensical for us.
27
+ print Annotations ({})
25
28
26
29
27
30
def test_dict_instantiation ():
Original file line number Diff line number Diff line change 7
7
"""
8
8
from nose .tools import raises
9
9
from ...graph_objs .graph_objs import *
10
- from ...exceptions import (PlotlyDictKeyError , PlotlyDictValueError ,
10
+ from ...exceptions import (PlotlyError ,
11
+ PlotlyDictKeyError ,
12
+ PlotlyDictValueError ,
11
13
PlotlyDataTypeError , PlotlyListEntryError )
12
14
13
15
@@ -20,8 +22,9 @@ def test_trivial():
20
22
assert Data () == list ()
21
23
22
24
25
+ @raises (PlotlyError )
23
26
def test_weird_instantiation (): # Python allows this...
24
- assert Data ({}) == list ({})
27
+ print Data ({})
25
28
26
29
27
30
def test_default_scatter ():
Original file line number Diff line number Diff line change @@ -14,8 +14,9 @@ def test_trivial():
14
14
assert PlotlyList () == list ()
15
15
16
16
17
+ @raises (PlotlyError )
17
18
def test_weird_instantiation ():
18
- assert PlotlyList ({}) == list ({})
19
+ print PlotlyList ({})
19
20
20
21
21
22
@raises (PlotlyError )
You can’t perform that action at this time.
0 commit comments