+def test_GermanPublicTransport():
+ v = wrpylib.wrvalidators.GermanPublicTransport()
+ assert v.to_python(u'') is None
+ assert v.to_python(u'Sehr gut') == 1
+ assert v.to_python(u'Gut') == 2
+ assert v.to_python(u'Mittelmäßig') == 3
+ assert v.to_python(u'Schlecht') == 4
+ assert v.to_python(u'Nein') == 5
+ assert v.to_python(u'Ja') == 6
+
+ assert v.from_python(None) == u''
+ assert v.from_python(1) == u'Sehr gut'
+ assert v.from_python(2) == u'Gut'
+ assert v.from_python(3) == u'Mittelmäßig'
+ assert v.from_python(4) == u'Schlecht'
+ assert v.from_python(5) == u'Nein'
+ assert v.from_python(6) == u'Ja'