pytest-voluptuous icon indicating copy to clipboard operation
pytest-voluptuous copied to clipboard

Assertion hook doesn't work

Open CharlesB2 opened this issue 3 years ago • 0 comments

Hello,

With Pytest 7.1 and Pytest-voluptuous 1.2.0, I don't get the proper assertion hook with assert S(schema) == some_dict:

Test session starts (platform: linux, Python 3.10.3, pytest 7.1.1, pytest-sugar 0.9.4)
cachedir: .pytest_cache
django: settings: ward_run_app.test_settings (from option)
rootdir: /app
plugins: Faker-13.3.4, forked-1.4.0, timeout-2.1.0, voluptuous-1.2.0, cov-3.0.0, xdist-2.5.0, profiling-1.7.0, sugar-0.9.4, icdiff-0.5, django-4.5.2, socket-0.5.1

    assert S(SCHEMA) == dict(data)
E   AssertionError: assert equals failed
E     <Schema({'id': <class 'int'>}, extra=PREVENT_EXTRA,
E required=True) 
E. object at 0xffff817f5f90>
E                                                                              {
E                                                                               'id': "hello"
E                                                                               }

CharlesB2 avatar Apr 04 '22 10:04 CharlesB2