Skip to content

Commit c8424dc

Browse files
committed
push
1 parent 0ec542e commit c8424dc

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

tests/test_langchain.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def test_callback_generated_from_trace_chat():
5151

5252
assert trace.id == trace_id
5353

54-
assert len(trace.observations) == 2
54+
assert len(trace.observations) == 3
5555

5656
langchain_generation_span = list(
5757
filter(
@@ -286,7 +286,7 @@ def test_openai_instruct_usage():
286286
observations = get_api().trace.get(trace_id).observations
287287

288288
# Add 1 to account for the wrapping span
289-
assert len(observations) == 3
289+
assert len(observations) == 4
290290

291291
for observation in observations:
292292
if observation.type == "GENERATION":
@@ -463,7 +463,7 @@ def test_link_langfuse_prompts_invoke():
463463
key=lambda x: x.start_time,
464464
)
465465

466-
assert len(generations) == 2
466+
assert len(generations) == 4
467467
assert generations[0].input == "Tell me a joke involving the animal dog"
468468
assert "Explain the joke to me like I'm a 5 year old" in generations[1].input
469469

@@ -550,7 +550,7 @@ def test_link_langfuse_prompts_stream():
550550
key=lambda x: x.start_time,
551551
)
552552

553-
assert len(generations) == 2
553+
assert len(generations) == 4
554554
assert generations[0].input == "Tell me a joke involving the animal dog"
555555
assert "Explain the joke to me like I'm a 5 year old" in generations[1].input
556556

@@ -639,7 +639,7 @@ def test_link_langfuse_prompts_batch():
639639
key=lambda x: x.start_time,
640640
)
641641

642-
assert len(generations) == 6
642+
assert len(generations) == 10
643643

644644
assert generations[0].prompt_name == joke_prompt_name
645645
assert generations[1].prompt_name == joke_prompt_name
@@ -856,7 +856,7 @@ def test_multimodal():
856856

857857
trace = get_api().trace.get(trace_id=trace_id)
858858

859-
assert len(trace.observations) == 2
859+
assert len(trace.observations) == 3
860860
# Filter for the observation with type GENERATION
861861
generation_observation = next(
862862
(obs for obs in trace.observations if obs.type == "GENERATION"), None

0 commit comments

Comments
 (0)