예제 #1
0
파일: test_main.py 프로젝트: Riptawr/hdfs
 def test_parse_int_list(self):
   eq_(parse_arg({'foo': '1,'}, 'foo', int, ','), [1])
   eq_(parse_arg({'foo': '1,2'}, 'foo', int, ','), [1,2])
예제 #2
0
파일: test_main.py 프로젝트: Riptawr/hdfs
 def test_parse_int(self):
   eq_(parse_arg({'foo': '1'}, 'foo', int), 1)
   eq_(parse_arg({'foo': '1'}, 'foo', int, ','), 1)
예제 #3
0
파일: test_main.py 프로젝트: Riptawr/hdfs
 def test_parse_float(self):
   eq_(parse_arg({'foo': '123.4'}, 'foo', float), 123.4)
예제 #4
0
파일: test_main.py 프로젝트: Riptawr/hdfs
 def test_parse_invalid(self):
   parse_arg({'foo': 'a'}, 'foo', int)
예제 #5
0
파일: test_main.py 프로젝트: wynhbh/hdfs
 def test_parse_int_list(self):
     eq_(parse_arg({'foo': '1,'}, 'foo', int, ','), [1])
     eq_(parse_arg({'foo': '1,2'}, 'foo', int, ','), [1, 2])
예제 #6
0
파일: test_main.py 프로젝트: wynhbh/hdfs
 def test_parse_float(self):
     eq_(parse_arg({'foo': '123.4'}, 'foo', float), 123.4)
예제 #7
0
파일: test_main.py 프로젝트: wynhbh/hdfs
 def test_parse_int(self):
     eq_(parse_arg({'foo': '1'}, 'foo', int), 1)
     eq_(parse_arg({'foo': '1'}, 'foo', int, ','), 1)
예제 #8
0
파일: test_main.py 프로젝트: wynhbh/hdfs
 def test_parse_invalid(self):
     parse_arg({'foo': 'a'}, 'foo', int)