File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
sdk/ai/Azure.AI.Projects/tests/Samples/Agent Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ public partial class Sample_Agent_Bing_Grounding : SamplesBase<AIProjectsTestEnv
1818 public async Task BingGroundingExample ( )
1919 {
2020 var connectionString = TestEnvironment . AzureAICONNECTIONSTRING ;
21+ var modelName = TestEnvironment . MODELDEPLOYMENTNAME ;
2122
2223 var clientOptions = new AIProjectClientOptions ( ) ;
2324
@@ -37,7 +38,7 @@ public async Task BingGroundingExample()
3738 BingGroundingToolDefinition bingGroundingTool = new BingGroundingToolDefinition ( connectionList ) ;
3839
3940 Response < Agent > agentResponse = await agentClient . CreateAgentAsync (
40- model : "gpt-4-1106-preview" ,
41+ model : modelName ,
4142 name : "my-assistant" ,
4243 instructions : "You are a helpful assistant." ,
4344 tools : new List < ToolDefinition > { bingGroundingTool } ) ;
@@ -65,6 +66,10 @@ public async Task BingGroundingExample()
6566 while ( runResponse . Value . Status == RunStatus . Queued
6667 || runResponse . Value . Status == RunStatus . InProgress ) ;
6768
69+ Assert . AreEqual (
70+ RunStatus . Completed ,
71+ runResponse . Value . Status ,
72+ runResponse . Value . LastError ? . Message ) ;
6873 Response < PageableList < ThreadMessage > > afterRunMessagesResponse
6974 = await agentClient . GetMessagesAsync ( thread . Id ) ;
7075 IReadOnlyList < ThreadMessage > messages = afterRunMessagesResponse . Value . Data ;
You can’t perform that action at this time.
0 commit comments