[issue4242] Classify language vs. impl-detail tests, step 1

Armin Rigo report at bugs.python.org
Tue Jan 13 15:31:45 CET 2009


Armin Rigo <arigo at users.sourceforge.net> added the comment:

Here is a summarizing implementation that accepts this interface:

    if check_impl_detail():               # only on CPython (default)
    if check_impl_detail(jython=True):    # only on Jython
    if check_impl_detail(cpython=False):  # everywhere except on CPython

and similarly with the decorator:

    @impl_detail()                # only on CPython (default)
    @impl_detail("reason...")     # the same, with an explicit message
    @impl_detail(jython=True)     # only on Jython
    @impl_detail(cpython=False)   # everywhere except on CPython

I think this is a nice interface, although it takes some largish number
of lines to implement.

Added file: http://bugs.python.org/file12718/test-impl-details-2.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4242>
_______________________________________


More information about the Python-bugs-list mailing list