File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change 1
1
import os
2
- from nose .tools import eq_
2
+ from nose .tools import eq_ , raises
3
3
from pyexcel ._compact import StringIO
4
4
from pyexcel_text .jsonp import JsonParser
5
5
@@ -9,6 +9,18 @@ class TestStructure:
9
9
def setUp (self ):
10
10
self .parser = JsonParser ("json" )
11
11
12
+ @raises (Exception )
13
+ def test_wrong_format (self ):
14
+ sheet_name = 'test'
15
+ self .content = self .parser .parse_file (get_file ("unknown.json" ),
16
+ sheet_name = sheet_name )
17
+
18
+ @raises (Exception )
19
+ def test_bad_dict (self ):
20
+ sheet_name = 'test'
21
+ self .content = self .parser .parse_file (get_file ("bad_dict.json" ),
22
+ sheet_name = sheet_name )
23
+
12
24
def test_dict (self ):
13
25
sheet_name = 'test'
14
26
self .content = self .parser .parse_file (get_file ("dict.json" ),
You can’t perform that action at this time.
0 commit comments