Skip to content

chore(integration): add WV_TEST_* host/port overrides for test instances#2023

Draft
mpartipilo wants to merge 1 commit intomainfrom
chore/test-endpoint-env-vars
Draft

chore(integration): add WV_TEST_* host/port overrides for test instances#2023
mpartipilo wants to merge 1 commit intomainfrom
chore/test-endpoint-env-vars

Conversation

@mpartipilo
Copy link
Copy Markdown

@mpartipilo mpartipilo commented Apr 28, 2026

Summary

Allow the integration suite's instance endpoints to be overridden via environment variables, matching a convention being introduced across the Weaviate clients. Override-only semantics — defaults preserve existing behavior.

  • Primary: WV_TEST_HOST / WV_TEST_REST_PORT (8080) / WV_TEST_GRPC_PORT (50051)
  • Auth: WV_TEST_AUTH_HOST / WV_TEST_AUTH_REST_PORT (8085) / WV_TEST_AUTH_GRPC_PORT (50056)
  • OIDC: WV_TEST_OIDC_HOST / WV_TEST_OIDC_OKTA_CC_PORT (8082) / WV_TEST_OIDC_OKTA_USERS_PORT (8083)

integration/conftest.py already covered the primary instance. This PR extends the same pattern to integration/test_auth.py: module-level port constants now read from env, and connect_to_local / is_auth_enabled call sites pass the matching host explicitly instead of hardcoding localhost.

Test plan

  • CI green on main

Generated with Claude Code

Copy link
Copy Markdown

@orca-security-eu orca-security-eu Bot left a comment

Choose a reason for hiding this comment

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

Orca Security Scan Summary

Status Check Issues by priority
Passed Passed Infrastructure as Code high 0   medium 0   low 0   info 0 View in Orca
Passed Passed SAST high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Secrets high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Vulnerabilities high 0   medium 0   low 0   info 0 View in Orca

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Apr 28, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.71%. Comparing base (78fa5f7) to head (3b50b5a).
⚠️ Report is 146 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2023      +/-   ##
==========================================
- Coverage   87.95%   86.71%   -1.24%     
==========================================
  Files         280      298      +18     
  Lines       21664    22890    +1226     
==========================================
+ Hits        19054    19849     +795     
- Misses       2610     3041     +431     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mpartipilo mpartipilo force-pushed the chore/test-endpoint-env-vars branch from 6cf94ae to 64c21cf Compare April 28, 2026 18:48
@mpartipilo mpartipilo changed the title chore(integration): rename test endpoint env vars to WV_TEST_*_ENDPOINT chore(integration): add WV_TEST_REST_PORT/WV_TEST_GRPC_PORT overrides Apr 28, 2026
Allow integration suite endpoints to be overridden via env vars,
falling back to current hardcoded defaults when unset:

  Primary  WV_TEST_HOST          / WV_TEST_REST_PORT (8080) / WV_TEST_GRPC_PORT (50051)
  Auth     WV_TEST_AUTH_HOST     / WV_TEST_AUTH_REST_PORT (8085) / WV_TEST_AUTH_GRPC_PORT (50056)
  OIDC     WV_TEST_OIDC_HOST     / WV_TEST_OIDC_OKTA_CC_PORT (8082) / WV_TEST_OIDC_OKTA_USERS_PORT (8083)

The conftest fixture API still takes a (rest_port, grpc_port) tuple
unchanged. test_auth.py module-level port constants now read from env
and connect_to_local / is_auth_enabled call sites pass the matching
host explicitly.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@mpartipilo mpartipilo force-pushed the chore/test-endpoint-env-vars branch from 64c21cf to 3b50b5a Compare April 28, 2026 19:11
@mpartipilo mpartipilo changed the title chore(integration): add WV_TEST_REST_PORT/WV_TEST_GRPC_PORT overrides chore(integration): add WV_TEST_* host/port overrides for test instances Apr 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants