chrisber <[EMAIL PROTECTED]> wrote: > I've poked around to see if I could delete the options my earlier code > consumed from the commandline buffer, before invoking unittest, but > that seems klugy. Instead, I hardwired in a testing config file name, > that always has to be local. That works pretty well, but it leaves me > wonderfing whether there would have been another clean way to allow > both my test code and unittest to have options without interfering > with one another. >
You can pass argv as a parameter to main(), so I think the best bet is simply to build up a new argv with the options that you want to pass through. Another option would be to subclass unittest.TestProgram and override parseArgs, but you'd have to copy & modify it as it doesn't seem to have been designed to be easily extendable. -- http://mail.python.org/mailman/listinfo/python-list