Pylons / pylons

Pylons Framework, community maintained with guidance/assistance from the Pylons Project. Merged with repoze.bfg for Pyramid framework.
Other
231 stars 76 forks source link

Some tests fail in non-English locales #3

Closed wRAR closed 9 years ago

wRAR commented 13 years ago

FAIL: test_hello_custom_failed (tests.test_units.test_decorator_validate.TestValidateDecorator) FAIL: test_hello_failed (tests.test_units.test_decorator_validate.TestValidateDecorator) FAIL: test_network_failed_validation_non_ascii (tests.test_units.test_decorator_validate.TestValidateDecorator)

That's because these tests expect English error messages and get translated ones. Reproducible in ru_RU.UTF-8 with Pylons 1.0 and git-72f4a5ed

cicku commented 11 years ago

Failure: SkipTest () ... SKIP

FAIL: test_network_failed_validation_non_ascii (tests.test_units.test_decorator_validate.TestValidateDecorator)

Traceback (most recent call last): File "/builddir/build/BUILD/Pylons-1.0.1/tests/test_units/test_decorator_validate.py", line 103, in test_network_failed_validation_non_ascii assert 'That is not a valid URL' in response AssertionError: -------------------- >> begin captured logging << -------------------- pylons.decorators: DEBUG: Validating against a schema pylons.decorators: DEBUG: Errors found in validation, parsing form with htmlfill for errors

--------------------- >> end captured logging << ---------------------

Ran 108 tests in 5.670s FAILED (SKIP=1, failures=1) RPM build errors: error: Bad exit status from /var/tmp/rpm-tmp.pbzc59 (%check)

bbangert commented 9 years ago

Actually, newer routes seems to handle this, the test works differently now. I've updated it so it reflects reality.