Mercurial > p > roundup > code
diff test/db_test_base.py @ 5234:d8457c376a38
Work around for missing fractional second support in our use of mysql.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Sat, 15 Apr 2017 17:09:10 -0400 |
| parents | ebc27b90aa3b |
| children | 9886917c8545 |
line wrap: on
line diff
--- a/test/db_test_base.py Fri Apr 14 23:58:35 2017 -0400 +++ b/test/db_test_base.py Sat Apr 15 17:09:10 2017 -0400 @@ -1070,6 +1070,16 @@ # also test that we can make a property noisy self.db.issue.properties['nosy'].quiet=False self.db.issue.properties['deadline'].quiet=False + + # FIXME: mysql use should be fixed or + # a different way of checking this should be done. + # this sleep is a hack. + # mysql transation timestamps are in whole + # seconds. To get the history to sort in proper + # order by using timestamps we have to sleep 2 seconds + # here tomake sure the timestamp between this transaction + # and the last transaction is at least 1 second apart. + import time; time.sleep(2) result=self.db.issue.set(new_issue, title="title2", deadline=date.Date('2016-7-13.22:39'), assignedto="2", nosy=["1", "2"])
