Page MenuHomeFreeBSD

tests/sys/opencrypto: use python3

Authored by asomers on Jul 16 2020, 3:10 AM.



tests/sys/opencrypto: use python3

python2 will be EOL soon

Diff Detail

rS FreeBSD src repository - subversion
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Looks good to me. I'm adding ngie as they did the port to Python 3. I have not run and verified that this works under Python 3, but fully support the move to 3.

It does look like some changes were made in the conversion that need to be addressed. Not all `` were converted to repr's, in the case of some of the unittest.skipIf. '%s' % strvar != '%s' % repr(strvar) in that if strvar has escape chars or other non-printables, they will corrupt the terminal or other damage whereas repr prevents that change.

Test fine from my side.

This revision is now accepted and ready to land.Jul 20 2020, 10:38 AM
This revision was automatically updated to reflect the committed changes.

This should work, for sure.

The removing from __future__ import print_function wasn't absolutely required, but it does clean up some of the move from python 2 to 3.