#6373 test_util.test_assert_deepequal fails
Closed: Fixed None Opened 7 years ago by stlaz.

The test_util.test_assert_deepequal test fails due to recent changes in pretty printing the structures in the exception string as the expected and got exception strings do not match.

        # Extra
        b = [
            u'hello',
            dict(naughty=u'nurse', barely=u'legal'),
            18,
        ]
        e = raises(AssertionError, f, a, b, 'foo')
>       assert str(e) == KEYS % ('foo',
            [], ['barely'],
            exp_str(dict(naughty=u'nurse')),
            got_str(dict(naughty=u'nurse', barely=u'legal')),
            (1,)
        )
E       assert 'assert_deepe...  path = (1,)' == 'assert_deepeq...  path = (1,)'
E         Skipping 125 identical leading characters in diff, use -v to show
E         -   got = {'naughty': u'nurse', 'barely': u'legal'}
E         +   got = {'barely': u'legal', 'naughty': u'nurse'}
E             path = (1,)

test_util.py:260: AssertionError

Regression caused by ticket #6212, moving to the same milestone.

master:

  • d70d718 Fix test_util.test_assert_deepequal test

ipa-4-4:

  • 6982929 Fix test_util.test_assert_deepequal test

Metadata Update from @stlaz:
- Issue assigned to stlaz
- Issue set to the milestone: FreeIPA 4.4.2

7 years ago

Login to comment on this ticket.

Metadata