@@ -238,8 +238,18 @@ def place_before(path, text, *before_text, escape=None):
238238 """@nox.session\(python=SYSTEM_TEST_PYTHON_VERSIONS\)
239239def system\(session\):""" ,
240240 """@nox.session(python=SYSTEM_TEST_PYTHON_VERSIONS)
241- @nox.parametrize("database_dialect", ["GOOGLE_STANDARD_SQL", "POSTGRESQL"])
242- def system(session, database_dialect):""" ,
241+ @nox.parametrize(
242+ "protobuf_implementation,database_dialect",
243+ [
244+ ("python", "GOOGLE_STANDARD_SQL"),
245+ ("python", "POSTGRESQL"),
246+ ("upb", "GOOGLE_STANDARD_SQL"),
247+ ("upb", "POSTGRESQL"),
248+ ("cpp", "GOOGLE_STANDARD_SQL"),
249+ ("cpp", "POSTGRESQL"),
250+ ],
251+ )
252+ def system(session, protobuf_implementation, database_dialect):""" ,
243253)
244254
245255s .replace (
@@ -248,6 +258,7 @@ def system(session, database_dialect):""",
248258 \)""" ,
249259 """*session.posargs,
250260 env={
261+ "PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION": protobuf_implementation,
251262 "SPANNER_DATABASE_DIALECT": database_dialect,
252263 "SKIP_BACKUP_TESTS": "true",
253264 },
@@ -345,6 +356,19 @@ def mockserver(session):
345356 escape = "()_*:" ,
346357)
347358
359+ s .replace (
360+ "noxfile.py" ,
361+ "install_systemtest_dependencies\(session, \" -c\" , constraints_path\)" ,
362+ """install_systemtest_dependencies(session, "-c", constraints_path)
363+
364+ # TODO(https://github.com/googleapis/synthtool/issues/1976):
365+ # Remove the 'cpp' implementation once support for Protobuf 3.x is dropped.
366+ # The 'cpp' implementation requires Protobuf<4.
367+ if protobuf_implementation == "cpp":
368+ session.install("protobuf<4")
369+ """
370+ )
371+
348372place_before (
349373 "noxfile.py" ,
350374 "UNIT_TEST_PYTHON_VERSIONS: List[str] = [" ,
0 commit comments