Mercurial > p > roundup > code
changeset 7881:2184033114a0
test: fix tests python3 can't sort dict.
Was getting
TypeError: '<' not supported between instances of 'dict' and 'dict'
on some result.sort() where result was a dict on windows. Not sure
why it wasn't happening on Linux but I don't see any requirement to
sort the dicts to make the test pass. Possibly sort() was a copy/paste
from an earlier test where a list or something was returned.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Thu, 18 Apr 2024 19:00:18 -0400 |
| parents | a4923cec0afa |
| children | 77c109725a7e |
| files | test/db_test_base.py |
| diffstat | 1 files changed, 0 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/test/db_test_base.py Thu Apr 18 18:57:49 2024 -0400 +++ b/test/db_test_base.py Thu Apr 18 19:00:18 2024 -0400 @@ -1259,7 +1259,6 @@ expected = {'nosy': (('+', ['1']), ('-', ['3'])), 'deadline': date.Date("2016-07-30.22:39:00.000")} - result.sort() print("result unquiet", result) (id, tx_date, user, action, args) = result[-1] # check piecewise @@ -1304,7 +1303,6 @@ # Verify last journal entry as admin is a role change # from None result=self.db.user.history(new_user, skipquiet=False) - result.sort() ''' result should end like: [ ... ('3', <Date 2017-04-15.02:06:11.482>, '1', 'set',
