check point
This commit is contained in:
32
VisionBuilder.UI.Recipes.Scripted.Tests/BasicSyntax.cs
Normal file
32
VisionBuilder.UI.Recipes.Scripted.Tests/BasicSyntax.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
namespace VisionBuilder.UI.Recipes.Scripted.Tests
|
||||
{
|
||||
public class Tests
|
||||
{
|
||||
|
||||
public void TestAddFunction(int a, int b, out int c)
|
||||
{
|
||||
c = a + b;
|
||||
}
|
||||
|
||||
[SetUp]
|
||||
public void Setup()
|
||||
{
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void Test1()
|
||||
{
|
||||
// setup
|
||||
// todo: register function
|
||||
|
||||
string script = @"
|
||||
test_add_function(1,2,c)
|
||||
";
|
||||
|
||||
int c = 0;
|
||||
// todo: get value of c from engine
|
||||
|
||||
Assert.Pass();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
|
||||
<IsPackable>false</IsPackable>
|
||||
<IsTestProject>true</IsTestProject>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="coverlet.collector" Version="6.0.0" />
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
|
||||
<PackageReference Include="NUnit" Version="3.14.0" />
|
||||
<PackageReference Include="NUnit.Analyzers" Version="3.9.0" />
|
||||
<PackageReference Include="NUnit3TestAdapter" Version="4.5.0" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Using Include="NUnit.Framework" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
Reference in New Issue
Block a user