Message345483
(Redirected here from https://bugs.python.org/issue37262)
I haven't dug the assertThat() idea, but why not make, as a first step, turn assertion methods in TestCase to staticmethods/classmethods, instead of instance methods?
Since they (to my knowledge) don't need to access an instance dict, they could be turned into such instance-less methods, and thus be usable from other testing frameworks (like pytest, for those who want to use pytest fixtures and yet benefit from advanced assertions like Django's TestCase's assertions).
"failureException" and others are meant to be (sub)class attributes, so no backwards incompatible change should occur (unless someone did really weird things with manually instantiated TestCases). |
|
Date |
User |
Action |
Args |
2019-06-13 09:28:55 | pakal | set | recipients:
+ pakal, ncoghlan, rbcollins, eric.araujo, r.david.murray, michael.foord, Julian, martin.panter, serhiy.storchaka, Gregory.Salvan |
2019-06-13 09:28:55 | pakal | set | messageid: <1560418135.51.0.216239411499.issue19645@roundup.psfhosted.org> |
2019-06-13 09:28:55 | pakal | link | issue19645 messages |
2019-06-13 09:28:55 | pakal | create | |
|