Skip to content

Commit 2bafd3c

Browse files
.
1 parent de56c78 commit 2bafd3c

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tests/integrations/pydantic_ai/test_pydantic_ai.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1221,9 +1221,12 @@ async def test_invoke_agent_with_instructions(
12211221
agent = Agent(
12221222
"test",
12231223
name="test_instructions",
1224-
system_prompt="System prompt",
12251224
)
12261225

1226+
# Add instructions via _instructions attribute (internal API)
1227+
agent._instructions = ["Instruction 1", "Instruction 2"]
1228+
agent._system_prompts = ["System prompt"]
1229+
12271230
sentry_init(
12281231
integrations=[PydanticAIIntegration(include_prompts=include_prompts)],
12291232
traces_sample_rate=1.0,
@@ -1234,7 +1237,6 @@ async def test_invoke_agent_with_instructions(
12341237

12351238
await agent.run(
12361239
"Test input",
1237-
instructions=["Instruction 1", "Instruction 2"],
12381240
)
12391241

12401242
(transaction,) = events

0 commit comments

Comments
 (0)