STINNER Victor added the comment:

Serhiy Storchaka wrote:
"""
You can just mover parts of the code into utility files (or to the test.support 
package) without converting regrtest.py to a package. This preserves 
compatibility with running Lib/test/regrtest.py as a script.
"""

Does it really matter? Who runs directly Lib/test/regrtest.py? It's simple to 
replace Lib/test/regrtest.py with -m test (or -m test.regrtest), no?

Serhiy Storchaka wrote: "Global variables are not evil in a script. Are there 
other reasons besides 
aesthetic?"

It's much easier to split a long function using multiple small functions when 
no global variable is used. I also like OOP, so I created a class. Should I 
understand that you don't like classes and would prefer to keep flat functions?

Martin Panter wrote:
"I never used --single, but quickly looking at the code, it looks like the 
pynexttest file got stored in /tmp or similar, via tempfile.gettempdir(), so it 
should usually survive. However it looks like your patch now creates 
“pynexttest” in a temporary directory that gets removed at the end?"

Ah ok, it's /tmp. I misunderstood the code. I understand that it creates a 
temporary subdirectory and write into the temporary subdirectory which will be 
removed.

Berker Peksag: "I like the new features, but I think we should take a look at 
issue 10967 before converting it to a package or refactoring it."

Even if we move some features to unittest, I don't think that regrtest.py will 
be reduced to fewer than 100 lines of code. By the way, most reusable code is 
in test.support. test.regrtest is much more specific to the CPython test suite, 
no?

Berker Peksag: "The buildbot part is also a bit complicated. For example, 
support.verbose doesn't work correctly on builtbots: issue 23235."

Sorry, I don't see the link with this issue. How are these two issues related?

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue25220>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to