More features

This commit is contained in:
gamer147
2026-05-23 14:18:01 -04:00
parent b2024af852
commit 6b70850b7b
59 changed files with 862 additions and 42033 deletions

View File

@@ -15,10 +15,21 @@
<PackageReference Include="NUnit3TestAdapter" Version="4.2.1" />
<PackageReference Include="NUnit.Analyzers" Version="3.6.1" />
<PackageReference Include="coverlet.collector" Version="6.0.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Testing" Version="8.0.8" />
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="8.0.8" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="8.0.8" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\SVSim.EmulatedEntrypoint\SVSim.EmulatedEntrypoint.csproj" />
</ItemGroup>
<ItemGroup>
<!-- BaseDataSeeder reads CSVs from the runtime "Data" folder; mirror them into the test
output so HasData seeding fires when EnsureCreated builds the SQLite schema. -->
<Content Include="..\SVSim.EmulatedEntrypoint\Data\*.csv" Link="Data\%(Filename)%(Extension)">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
</ItemGroup>
</Project>

View File

@@ -1,21 +1,10 @@
using SVSim.EmulatedEntrypoint.Services;
namespace SVSim.UnitTests;
public class Tests
public class SmokeTests
{
[SetUp]
public void Setup()
{
}
[Test]
public void Test1()
public void CanLoadAssembly()
{
const string ticket =
"140000005ee7d30c1263e214e133a10001001001e07cd866180000000100000002000000b8526bb7b8946cd27c214574f1000000b20000003200000004000000e133a1000100100168eb0600488cc2443101a8c0000000008165d4660115f06601005c7e010000000000cad61456a2b83d39595c3e3749b96b4537ebde88d048103a6f6c7b2b81ee68711378836872a11422f5bd16fad803f81122c5ae98d986b693bbbc00ac7d30a8f85af2c1a7dce57751eb2c7f21130284aa8d9ee787246c8ccc138f05936bacb1ba4baba5fa5fbf6158002cf7207ae25a6f6ee8e3fc8edbb84903d346a249179637";
using var steamService = new SteamSessionService();
bool validTicket = steamService.IsTicketValidForUser(ticket, 76561197970830305);
Assert.That(validTicket, Is.EqualTo(true));
Assert.That(typeof(SVSim.EmulatedEntrypoint.Program).Assembly, Is.Not.Null);
}
}
}