diff options
author | Jan Cholasta <jcholast@redhat.com> | 2013-01-08 16:32:41 +0100 |
---|---|---|
committer | Martin Kosek <mkosek@redhat.com> | 2013-02-08 15:16:37 +0100 |
commit | 1d35043e466dfca22cdaf463b6623c10a9ff2d39 (patch) | |
tree | 2b6e9a66c0e8b6db589d1a706e3de079566b9b1e /tests | |
parent | cbb262dc07ea0615068a630e6c7136e3200d5a06 (diff) | |
download | freeipa-1d35043e466dfca22cdaf463b6623c10a9ff2d39.tar.gz freeipa-1d35043e466dfca22cdaf463b6623c10a9ff2d39.tar.xz freeipa-1d35043e466dfca22cdaf463b6623c10a9ff2d39.zip |
Raise ValidationError on invalid CSV values.
https://fedorahosted.org/freeipa/ticket/3323
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_ipalib/test_parameters.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/test_ipalib/test_parameters.py b/tests/test_ipalib/test_parameters.py index b30ae5ada..12270a94f 100644 --- a/tests/test_ipalib/test_parameters.py +++ b/tests/test_ipalib/test_parameters.py @@ -631,6 +631,10 @@ class test_Param(ClassChecker): assert type(n) is tuple assert len(n) is 3 + e = raises(ValidationError, o.split_csv, '"a') + assert e.name == 'my_list' + assert e.error == u'Improperly formatted CSV value (newline inside string)' + def test_split_csv_separator(self): """ Test the `ipalib.parameters.Param.split_csv` method with csv and a separator. |