Code

Opened 5 years ago

Closed 5 years ago

#10988 closed (fixed)

timeuntil regressiontests fail

Reported by: gsong Owned by: nobody
Component: Core (Other) Version: master
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

The doctests for timeuntil had extra spaces at the end, causing the tests to fail:

E:\blog\django\tests\regressiontests\utils>tests
**********************************************************************
File "E:\blog\django\tests\regressiontests\utils\tests.py", line 92, in __main__
.__test__.timesince
Failed example:
    timeuntil(today+oneday, today)
Expected:
    u'1 day'
Got:
    u'1 day'
**********************************************************************
File "E:\blog\django\tests\regressiontests\utils\tests.py", line 94, in __main__
.__test__.timesince
Failed example:
    timeuntil(today-oneday, today)
Expected:
    u'0 minutes'
Got:
    u'0 minutes'
**********************************************************************
File "E:\blog\django\tests\regressiontests\utils\tests.py", line 96, in __main__
.__test__.timesince
Failed example:
    timeuntil(today+oneweek, today)
Expected:
    u'1 week'
Got:
    u'1 week'
**********************************************************************
1 items had failures:
   3 of  47 in __main__.__test__.timesince
***Test Failed*** 3 failures.

The patch merely removes the extra spaces from the expected results.

Attachments (1)

10988-test_utils_timesince-r10665.patch (543 bytes) - added by gsong 5 years ago.
Patch to remove extra spaces in doctest

Download all attachments as: .zip

Change History (3)

Changed 5 years ago by gsong

Patch to remove extra spaces in doctest

comment:1 Changed 5 years ago by Alex

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted

comment:2 Changed 5 years ago by SmileyChris

  • Resolution set to fixed
  • Status changed from new to closed

Seems fine in r11453

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.