4 references to Create
Microsoft.Extensions.AI.Tests (4)
Functions\AIFunctionFactoryTest.cs (4)
19
Assert.Throws<ArgumentNullException>("method", () => AIFunctionFactory.
Create
(method: null!, target: new object()));
20
Assert.Throws<ArgumentNullException>("method", () => AIFunctionFactory.
Create
(method: null!, target: new object(), name: "myAiFunk"));
21
Assert.Throws<ArgumentNullException>("target", () => AIFunctionFactory.
Create
(typeof(AIFunctionFactoryTest).GetMethod(nameof(InvalidArguments_Throw))!, null));
22
Assert.Throws<ArgumentException>("method", () => AIFunctionFactory.
Create
(typeof(List<>).GetMethod("Add")!, new List<int>()));