test: add comprehensive unit tests for SegmentService - Fix: #28656 (#28568)

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
This commit is contained in:
authored and GitHub committed 2025-11-26 09:43:00 +08:00
1 parent 203c2f0456
commit e4ec4e1470
2 files changed
+1098 -1

No files matched your search

@@ -295,9 +295,13 @@ class TestAPIBasedExtensionService:
original_name = created_extension.name
original_endpoint = created_extension.api_endpoint
# Update the extension
# Update the extension with guaranteed different values
new_name = fake.company()
# Ensure new endpoint is different from original
new_endpoint = f"https://{fake.domain_name()}/api"
# If by chance they're the same, generate a new one
while new_endpoint == original_endpoint:
new_endpoint = f"https://{fake.domain_name()}/api"
new_api_key = fake.password(length=20)
created_extension.name = new_name
File diff suppressed because it is too large. Load diff