On Wed, Feb 12, 2014 at 1:56 PM, Marc Aymerich <glicer...@gmail.com> wrote: > I'm running my Django app tests and I'm getting a random and very > annoying assertion error > > ====================================================================== > FAIL: test_rest_dns_delete > (orchestra.apps.dns.zones.tests.functional_tests.tests.RESTBind9MasterBackendTest) > ---------------------------------------------------------------------- > Traceback (most recent call last): > File > "/home/orchestra/django-orchestra/orchestra/apps/dns/zones/tests/functional_tests/tests.py", > line 212, in test_rest_dns_delete > self.validate_delete() > File > "/home/orchestra/django-orchestra/orchestra/apps/dns/zones/tests/functional_tests/tests.py", > line 86, in validate_delete > self.assertNotEqual('%s.' % self.zone.name_server, soa[4]) > AssertionError: u'ns.example.com.' == 'ns.example.com.' > > ---------------------------------------------------------------------- > > WTF is wrong with it? > The thing is that I don't always get the error, just like 1/4 of the > times, and a manual assertion like this never fails ! > > self.assertEqual(u'ns.example.com.', 'ns.example.com.') > > > Any clue? > > Thank you guys!
In your test output you have assertNotEqual and in your manual assertion you have assertEqual. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CACwCsY6wpFqkOr2HHP1qPTxngq7bz_WQ%2B%2BD8d1EybLxSd5OBxA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.