Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion genai/template_folder/test_templatefolder_examples.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

import templatefolder_with_txt

os.environ["GOOGLE_GENAI_USE_VERTEXAI"] = "True"
os.environ["GOOGLE_GENAI_USE_ENTERPRISE"] = "True"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Setting environment variables at the module level in tests modifies global state and can cause side effects. Additionally, 'GOOGLE_GENAI_USE_ENTERPRISE' is not used by 'templatefolder_with_txt.py', making this dead code in this context. For a template, it is better to remove unnecessary boilerplate or use a scoped fixture (e.g., 'monkeypatch') to ensure test isolation.

os.environ["GOOGLE_CLOUD_LOCATION"] = "global" # "us-central1"
# The project name is included in the CICD pipeline
# os.environ['GOOGLE_CLOUD_PROJECT'] = "add-your-project-name"
Expand Down