def test_parse_n_lname_with_space(): test_line = 'N:LName WSpace;FName;;;' results = pv.parse_n(test_line) assert results[0] == 'FName' assert results[1] == 'LName WSpace'
def test_parse_n(): test_line = 'N:LName;FName;;;' results = pv.parse_n(test_line) assert results[0] == 'FName' assert results[1] == 'LName'
def test_parse_n_too_many_fields(): test_line = 'N:ManyFields;Too;;;;;;;' results = pv.parse_n(test_line) assert results[0] == 'Too' assert results[1] == 'ManyFields'
def test_parse_n_no_names(): test_line = 'N:;;;;' results = pv.parse_n(test_line) assert results[0] == '' assert results[1] == ''
def test_parse_n_no_lname(): test_line = 'N:;FName;;;' results = pv.parse_n(test_line) assert results[0] == 'FName' assert results[1] == ''
def test_parse_n_no_fname(): test_line = 'N:LName;;;;' results = pv.parse_n(test_line) assert results[0] == '' assert results[1] == 'LName'