Commit ff021ca
committed
Fix test failure when run alone.
testPasswordMigration was failing when run pytest -k
testPasswordMigration. Was always failing on third test.
When run as part of whole FormTestCase class it worked.
Fixed it by:
Using cl.db after call to actions.LoginAction.
Make sure to set cl.db.Otk = self.db.Otk before calling LoginAction.
Add real Otk database and not a mock to a couple of db's.
Without this the third element in the loop (crypt at this point) still
has the old vale when eading from db. I think this is due to the
original cl.db being closed inside LoginAction (to re-open db using
new user's credentials cl.db.ptimize is not set). I think the old
self.db is returning the cached values. At least that's my guess.1 parent 906f6bc commit ff021ca
1 file changed
+5
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
575 | 575 | | |
576 | 576 | | |
577 | 577 | | |
578 | | - | |
| 578 | + | |
579 | 579 | | |
580 | 580 | | |
581 | 581 | | |
| 582 | + | |
582 | 583 | | |
583 | 584 | | |
584 | 585 | | |
585 | 586 | | |
586 | 587 | | |
587 | | - | |
| 588 | + | |
588 | 589 | | |
589 | 590 | | |
590 | 591 | | |
| |||
1888 | 1889 | | |
1889 | 1890 | | |
1890 | 1891 | | |
| 1892 | + | |
1891 | 1893 | | |
1892 | 1894 | | |
1893 | 1895 | | |
| |||
3056 | 3058 | | |
3057 | 3059 | | |
3058 | 3060 | | |
| 3061 | + | |
3059 | 3062 | | |
3060 | 3063 | | |
3061 | 3064 | | |
| |||
0 commit comments