Skip to content

Commit 60a18b5

Browse files
committed
push
1 parent 65e5473 commit 60a18b5

1 file changed

Lines changed: 9 additions & 5 deletions

File tree

tests/test_core_sdk.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1397,7 +1397,7 @@ def test_get_generations():
13971397
sleep(3)
13981398

13991399
# Fetch generations using API
1400-
generations = get_api().observations.get_many(name=generation_name)
1400+
generations = get_api().legacy.observations_v1.get_many(name=generation_name)
14011401

14021402
# Verify fetched generation matches what we created
14031403
assert len(generations.data) == 1
@@ -1436,7 +1436,9 @@ def test_get_generations_by_user():
14361436
sleep(3)
14371437

14381438
# Fetch generations by user ID using the API
1439-
generations = get_api().observations.get_many(user_id=user_id, type="GENERATION")
1439+
generations = get_api().legacy.observations_v1.get_many(
1440+
user_id=user_id, type="GENERATION"
1441+
)
14401442

14411443
# Verify fetched generation matches what we created
14421444
assert len(generations.data) == 1
@@ -1770,7 +1772,7 @@ def test_get_observations():
17701772
sleep(2)
17711773

17721774
# Fetch observations using the API
1773-
observations = get_api().observations.get_many(name=name, limit=10)
1775+
observations = get_api().legacy.observations_v1.get_many(name=name, limit=10)
17741776

17751777
# Verify fetched observations
17761778
assert len(observations.data) == 2
@@ -1785,7 +1787,9 @@ def test_get_observations():
17851787
assert gen2_id in gen_ids
17861788

17871789
# Test pagination
1788-
paginated_response = get_api().observations.get_many(name=name, limit=1, page=2)
1790+
paginated_response = get_api().legacy.observations_v1.get_many(
1791+
name=name, limit=1, page=2
1792+
)
17891793
assert len(paginated_response.data) == 1
17901794
assert paginated_response.meta.total_items == 2 # Parent span + 2 generations
17911795
assert paginated_response.meta.total_pages == 2
@@ -1813,7 +1817,7 @@ def test_get_traces_empty():
18131817

18141818
def test_get_observations_empty():
18151819
# Fetch observations with a filter that should return no results
1816-
response = get_api().observations.get_many(name=create_uuid())
1820+
response = get_api().legacy.observations_v1.get_many(name=create_uuid())
18171821

18181822
assert len(response.data) == 0
18191823
assert response.meta.total_items == 0

0 commit comments

Comments
 (0)