I've been doing some work adding doctests to some files that don't have them, and the coverage script kept telling me to put in a "TestSuite.run()" doctest.
Can someone tell me how on earth I can get one of these to actually work? No matter what I do, if X is a parent object, "TestSuite(X).run()" always fails at the point where it creates an element of X and runs "_test_category" on it. It seems to want elements of X to be instances of a "dynamic metaclass" created on the fly by the categories machinery. How is that supposed to work? How are rich, complicated objects (e.g. ideals in arbitrary rings -- I was working on rings/ideal_monoid.py) supposed to be represented by a class that's cooked up out of nowhere? I looked for examples where TestSuite doctests already exist (and pass), but in all the ones I found either the element class didn't really do anything (e.g. the examples in sage/categories/examples) or the element class was a Cython extension type and thus exempt from this test. How can I make these tests pass, without drastic and undesirable rearrangement of the code? David -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org