Skip to content

Commit

Permalink
Merge pull request #4092 from boegel/py311
Browse files Browse the repository at this point in the history
also run unit tests with Python 3.11
  • Loading branch information
branfosj authored Dec 10, 2022
2 parents f33c74e + 70ada54 commit b91c795
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/eb_command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
python: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, '3.10']
python: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, '3.10', '3.11']
fail-fast: false
steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, '3.10']
python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, '3.10', '3.11']

steps:
- uses: actions/checkout@v3
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,12 @@ jobs:
- python: '3.10'
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Tcl
- python: '3.11'
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Lua
- python: '3.11'
modules_tool: ${{needs.setup.outputs.lmod8}}
module_syntax: Tcl
# There may be encoding errors in Python 3 which are hidden when an UTF-8 encoding is set
# Hence run the tests (again) with LC_ALL=C and Python 3.6 (or any < 3.7)
- python: 3.6
Expand Down Expand Up @@ -209,7 +215,7 @@ jobs:
# run test suite
python -O -m test.framework.suite 2>&1 | tee test_framework_suite.log
# try and make sure output of running tests is clean (no printed messages/warnings)
IGNORE_PATTERNS="no GitHub token available|skipping SvnRepository test|requires Lmod as modules tool|stty: 'standard input': Inappropriate ioctl for device|CryptographyDeprecationWarning: Python 3.[56]|from cryptography.*default_backend|CryptographyDeprecationWarning: Python 2|from cryptography.utils import int_from_bytes|Blowfish"
IGNORE_PATTERNS="no GitHub token available|skipping SvnRepository test|requires Lmod as modules tool|stty: 'standard input': Inappropriate ioctl for device|CryptographyDeprecationWarning: Python 3.[56]|from cryptography.*default_backend|CryptographyDeprecationWarning: Python 2|from cryptography.utils import int_from_bytes|Blowfish|GC3Pie not available, skipping test"
# '|| true' is needed to avoid that Travis stops the job on non-zero exit of grep (i.e. when there are no matches)
PRINTED_MSG=$(egrep -v "${IGNORE_PATTERNS}" test_framework_suite.log | grep '\.\n*[A-Za-z]' || true)
test "x$PRINTED_MSG" = "x" || (echo "ERROR: Found printed messages in output of test suite\n${PRINTED_MSG}" && exit 1)
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ flake8

# 2.6.7 uses invalid Python 2 syntax
GC3Pie!=2.6.7; python_version < '3.0'
GC3Pie; python_version >= '3.0'
GC3Pie; python_version >= '3.0' and python_version < '3.11'
python-graph-dot
python-hglib
requests
Expand All @@ -31,7 +31,7 @@ archspec

# cryptography 3.4.0 no longer supports Python 2.7
cryptography==3.3.2; python_version == '2.7'
cryptography; python_version >= '3.5'
cryptography; python_version >= '3.5' and python_version < '3.11'

# rich is only supported for Python 3.6+
rich; python_version >= '3.6'

0 comments on commit b91c795

Please sign in to comment.