コード例 #1
0
 def test_None(self):
     assert aslist(None) == []
コード例 #2
0
 def test_nonstring(self):
     assert aslist(55) == [55]
コード例 #3
0
 def test_already_list(self):
     assert aslist([55]) == [55]
コード例 #4
0
 def test_fine(self):
     assert aslist('first,   second, third',
                   ',') == ['first', 'second', 'third']
     assert aslist('first second     third') == ['first', 'second', 'third']
     assert aslist('first,   second, third', ',',
                   False) == ['first', '   second', ' third']
コード例 #5
0
ファイル: test_converters.py プロジェクト: TurboGears/tg2
 def test_None(self):
     assert aslist(None) == []
コード例 #6
0
ファイル: test_converters.py プロジェクト: TurboGears/tg2
 def test_already_list(self):
     assert aslist([55]) == [55]
コード例 #7
0
ファイル: test_converters.py プロジェクト: TurboGears/tg2
 def test_nonstring(self):
     assert aslist(55) == [55]
コード例 #8
0
ファイル: test_converters.py プロジェクト: TurboGears/tg2
 def test_fine(self):
     assert aslist('first,   second, third', ',') == ['first', 'second', 'third']
     assert aslist('first second     third') == ['first', 'second', 'third']
     assert aslist('first,   second, third', ',', False) == ['first', '   second', ' third']