Opened 10 years ago

Closed 10 years ago

Last modified 9 years ago

#14947 closed (fixed)

regressiontests.fixtures_regress.tests.TestFixtures.test_dumpdata_uses_default_manager() fails with Python 2.7

Reported by: Arfrever Owned by: nobody
Component: Uncategorized Version: 1.2
Severity: Keywords: blocker, regression
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


regressiontests.fixtures_regress.tests.TestFixtures.test_dumpdata_uses_default_manager() fails with Python 2.7. This test passes with Python 2.6.

FAIL: test_dumpdata_uses_default_manager (regressiontests.fixtures_regress.tests.TestFixtures)
Traceback (most recent call last):
  File "/var/tmp/portage/dev-python/django-1.2.4/work/Django-1.2.4/tests/regressiontests/fixtures_regress/", line 335, in test_dumpdata_uses_default_manager
    self.assertEqual(len(data), len('[%s]' % ', '.join([lion_json, emu_json, platypus_json])))
AssertionError: 426 != 441


Change History (9)

comment:1 Changed 10 years ago by Russell Keith-Magee

milestone: 1.3
Triage Stage: UnreviewedAccepted

Confirmed; test fails under Python2.7, using Django 1.2.4. Doesn't fail for trunk, or using Python 2.6.

This is therefore a 1.3 blocker.

comment:2 Changed 10 years ago by Russell Keith-Magee

Looks like this is just an output formatting difference; A decimal value is getting output as "2.2000000000000002" under Python 2.6, but as "2.2" under Python 2.7.

comment:3 Changed 10 years ago by Karen Tracey

Easy fix (I think) would then be to just change the test data to a value that does not differ between Pythons...this is what we did for #12562.

comment:4 Changed 10 years ago by Russell Keith-Magee

Keywords: blocker regression added

comment:5 Changed 10 years ago by Travis Cline

Resolution: fixed
Status: newclosed

This was fixed in [14309] by Luke

comment:6 Changed 10 years ago by Russell Keith-Magee

Resolution: fixed
Status: closedreopened

It may have been fixed on trunk, but the report is for the 1.2 branch. Looks like 14309 needs to be backported.

comment:7 Changed 10 years ago by Travis Cline

Ah, my mistake.

comment:8 Changed 10 years ago by Luke Plant

Resolution: fixed
Status: reopenedclosed

(In [15165]) [1.2.X] Fixed test failure when using Python 2.7

Backport of [14309] from trunk.

Fixed #14947

comment:9 Changed 9 years ago by Jacob

milestone: 1.3

Milestone 1.3 deleted

Note: See TracTickets for help on using tickets.
Back to Top