File tree Expand file tree Collapse file tree 3 files changed +21
-3
lines changed Expand file tree Collapse file tree 3 files changed +21
-3
lines changed Original file line number Diff line number Diff line change 5050 # to use your own Cloud project.
5151 'gcloud_project_env': 'GOOGLE_CLOUD_PROJECT',
5252 # 'gcloud_project_env': 'BUILD_SPECIFIC_GCLOUD_PROJECT',
53-
53+ # If you need to use a specific version of pip,
54+ # change pip_version_override to the string representation
55+ # of the version number, for example, "20.2.4"
56+ "pip_version_override": None,
5457 # A dictionary you want to inject into your test. Don't put any
5558 # secrets here. These values will override predefined values.
5659 'envs': {},
@@ -170,6 +173,9 @@ def blacken(session: nox.sessions.Session) -> None:
170173
171174
172175def _session_tests(session: nox.sessions.Session, post_install: Callable = None) -> None:
176+ if TEST_CONFIG["pip_version_override"]:
177+ pip_version = TEST_CONFIG["pip_version_override"]
178+ session.install(f"pip=={pip_version}")
173179 """Runs py.test for a particular project."""
174180 if os.path.exists("requirements.txt"):
175181 if os.path.exists("constraints.txt"):
Original file line number Diff line number Diff line change 5050 # to use your own Cloud project.
5151 'gcloud_project_env': 'GOOGLE_CLOUD_PROJECT',
5252 # 'gcloud_project_env': 'BUILD_SPECIFIC_GCLOUD_PROJECT',
53-
53+ # If you need to use a specific version of pip,
54+ # change pip_version_override to the string representation
55+ # of the version number, for example, "20.2.4"
56+ "pip_version_override": None,
5457 # A dictionary you want to inject into your test. Don't put any
5558 # secrets here. These values will override predefined values.
5659 'envs': {},
@@ -170,6 +173,9 @@ def blacken(session: nox.sessions.Session) -> None:
170173
171174
172175def _session_tests(session: nox.sessions.Session, post_install: Callable = None) -> None:
176+ if TEST_CONFIG["pip_version_override"]:
177+ pip_version = TEST_CONFIG["pip_version_override"]
178+ session.install(f"pip=={pip_version}")
173179 """Runs py.test for a particular project."""
174180 if os.path.exists("requirements.txt"):
175181 if os.path.exists("constraints.txt"):
Original file line number Diff line number Diff line change 5050 # to use your own Cloud project.
5151 'gcloud_project_env': 'GOOGLE_CLOUD_PROJECT',
5252 # 'gcloud_project_env': 'BUILD_SPECIFIC_GCLOUD_PROJECT',
53-
53+ # If you need to use a specific version of pip,
54+ # change pip_version_override to the string representation
55+ # of the version number, for example, "20.2.4"
56+ "pip_version_override": None,
5457 # A dictionary you want to inject into your test. Don't put any
5558 # secrets here. These values will override predefined values.
5659 'envs': {},
@@ -170,6 +173,9 @@ def blacken(session: nox.sessions.Session) -> None:
170173
171174
172175def _session_tests(session: nox.sessions.Session, post_install: Callable = None) -> None:
176+ if TEST_CONFIG["pip_version_override"]:
177+ pip_version = TEST_CONFIG["pip_version_override"]
178+ session.install(f"pip=={pip_version}")
173179 """Runs py.test for a particular project."""
174180 if os.path.exists("requirements.txt"):
175181 if os.path.exists("constraints.txt"):
You can’t perform that action at this time.
0 commit comments