diff --git a/CHANGES.txt b/CHANGES.txt index a3aa6091..949d23e4 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -5,7 +5,7 @@ CHANGES 3.6.1 (unreleased) ------------------ -- Nothing changed yet. +- Fix tests for changes in zope.schema validation errors. 3.6 (2017-12-20) diff --git a/setup.py b/setup.py index c6699bdb..7161be18 100644 --- a/setup.py +++ b/setup.py @@ -111,6 +111,7 @@ def alltests(): 'zc.sourcefactory', 'zope.container', 'zope.password', + 'zope.schema >= 4.6.0', 'zope.testing', ], adding=['zope.app.container >= 3.7'], @@ -145,6 +146,7 @@ def alltests(): 'zc.sourcefactory', 'zope.container', 'zope.password', + 'zope.schema >= 4.6.0', 'zope.testing', 'zope.testrunner', ], diff --git a/src/z3c/form/browser/checkbox.txt b/src/z3c/form/browser/checkbox.txt index 8188bb86..0532fbe5 100644 --- a/src/z3c/form/browser/checkbox.txt +++ b/src/z3c/form/browser/checkbox.txt @@ -218,8 +218,8 @@ the value (which is used as a backup label) contains non-ASCII characters: 'name': 'widget.name:list', 'value': 'no...'}] -Note: The "\234" character is interpreted differently in Pytohn 2 and 3 -here. (This is mostly due to changes int he SimpleVocabulary code.) +Note: The "\234" character is interpreted differently in Python 2 and 3 +here. (This is mostly due to changes in the SimpleVocabulary code.) Single Checkbox Widget diff --git a/src/z3c/form/browser/objectmulti.txt b/src/z3c/form/browser/objectmulti.txt index 790fbf20..b4753682 100644 --- a/src/z3c/form/browser/objectmulti.txt +++ b/src/z3c/form/browser/objectmulti.txt @@ -196,7 +196,7 @@ just cry about it in the HTML: * -
Wrong contained type
+
An object failed schema or invariant validation.
>> conv.toFieldValue('3.4') Traceback (most recent call last): ... - ValueError: invalid literal for int(): 3.4 + InvalidIntLiteral: invalid literal for int(): 3.4 Also, the conversion to the field value also validates the data; in this case negative values are not allowed: diff --git a/src/z3c/form/term.txt b/src/z3c/form/term.txt index 044d28ec..4c104f51 100644 --- a/src/z3c/form/term.txt +++ b/src/z3c/form/term.txt @@ -117,7 +117,7 @@ Initially we get an error because the "Ratings" vocabulary is not defined: ... None, request, None, ratingField2, widget) Traceback (most recent call last): ... - VocabularyRegistryError: unknown vocabulary: 'Ratings' + MissingVocabularyError: Can't validate value without vocabulary named 'Ratings' Let's now register the vocabulary under this name: