Update the upper bound for Python and Gerrit tests

OpenDev is preparing to upgrade its Gerrit deployment to 3.9, so
make sure git-review is working with the latest 3.9 point release.
This also requires a newer JDK.

While we're at it, switch from testing with Python 3.11 to 3.12
since that's ending up in more user environments these days.

Also drop unit test jobs that exercise old Python with new Gerrit
and new Python with old Gerrit to simplify the test matrix, because
our Python 3.6 platform lacks new enough Java to support current
Gerrit releases.

And since the Python 3.12 testing uses a platform with newer tools,
remove an unnecessary Git command output assert where the output has
diverged significantly from version to version, trusting that Git
will do what it's asked to do because we're not interested in
testing it for regressions anyway.

Depends-On: https://review.opendev.org/920841
Change-Id: Idb1af841ba68a6f536117ef64f3bec011e905203
This commit is contained in:
Jeremy Stanley 2024-05-30 15:59:47 +00:00
parent b65c3c201c
commit b0f82029d8
3 changed files with 8 additions and 26 deletions

View File

@ -4,23 +4,12 @@
nodeset: ubuntu-bionic
- job:
name: nox-py36-gerrit-371
parent: nox-py36-gerrit-default
name: nox-py312-gerrit-395
parent: nox-py312
nodeset: ubuntu-noble
vars:
nox_environment:
WAR_URL: 'https://gerrit-releases.storage.googleapis.com/gerrit-3.7.1.war'
- job:
name: nox-py311-gerrit-default
parent: nox-py311
nodeset: ubuntu-jammy
- job:
name: nox-py311-gerrit-371
parent: nox-py311-gerrit-default
vars:
nox_environment:
WAR_URL: 'https://gerrit-releases.storage.googleapis.com/gerrit-3.7.1.war'
WAR_URL: 'https://gerrit-releases.storage.googleapis.com/gerrit-3.9.5.war'
- project:
vars:
@ -32,9 +21,7 @@
- build-python-release
- nox-linters
- nox-py36-gerrit-default
- nox-py36-gerrit-371
- nox-py311-gerrit-default
- nox-py311-gerrit-371
- nox-py312-gerrit-395
gate:
jobs: *jobs
promote:

View File

@ -2,4 +2,5 @@
# install and tests; see http://docs.opendev.org/opendev/bindep/ for additional
# information.
openjdk-11-jdk [test]
openjdk-11-jdk [test platform:ubuntu-bionic]
openjdk-17-jdk [test platform:ubuntu-noble]

View File

@ -19,7 +19,6 @@ import json
import os
import shutil
import tempfile
import testtools
from git_review import tests
from git_review.tests import utils
@ -431,12 +430,7 @@ class GitReviewTestCase(tests.BaseGitReviewTestCase):
'maint', head_1)
self._run_git('fetch')
br_out = self._run_git('checkout',
'-b', 'test_branch', 'origin/maint')
expected_track = (".*\nBranch '?test_branch'? set up to track remote "
"branch '?maint'? from '?origin'?.")
track_matcher = testtools.matchers.MatchesRegex(expected_track)
self.assertThat(br_out, track_matcher)
self._run_git('checkout', '-b', 'test_branch', 'origin/maint')
branches = self._run_git('branch', '-a')
expected_branch = '* test_branch'
observed = branches.split('\n')