Added tests and void accounts/envelopes
This commit is contained in:
parent
ddde019173
commit
1b646745c8
6
.vscode/launch.json
vendored
6
.vscode/launch.json
vendored
@ -4,6 +4,12 @@
|
||||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
||||
"version": "0.2.0",
|
||||
"configurations": [
|
||||
{
|
||||
"name": "C#: <project-name> Debug",
|
||||
"type": "dotnet",
|
||||
"request": "launch",
|
||||
"projectPath": "${workspaceFolder}/active-allocator/bin/Debug/net7.0/linux-x64/active-allocator.dll"
|
||||
},
|
||||
{
|
||||
"name": ".NET Core Launch (web)",
|
||||
"type": "coreclr",
|
||||
|
29
active-allocator.Tests/AccountServiceTests.cs
Normal file
29
active-allocator.Tests/AccountServiceTests.cs
Normal file
@ -0,0 +1,29 @@
|
||||
namespace active_allocator.Tests;
|
||||
|
||||
public class AccountServiceTests
|
||||
{
|
||||
[Fact]
|
||||
public void PassingTest()
|
||||
{
|
||||
// Arrange
|
||||
int a = 2;
|
||||
int b = 2;
|
||||
|
||||
// Act
|
||||
int result = Add(2, 2);
|
||||
|
||||
// Assert
|
||||
Assert.Equal(4, result);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void FailingTest()
|
||||
{
|
||||
Assert.Equal(5, Add(2, 2));
|
||||
}
|
||||
|
||||
int Add(int x, int y)
|
||||
{
|
||||
return x + y;
|
||||
}
|
||||
}
|
14
active-allocator.Tests/DatabaseFixture.cs
Normal file
14
active-allocator.Tests/DatabaseFixture.cs
Normal file
@ -0,0 +1,14 @@
|
||||
public class DatabaseFixture : IDisposable
|
||||
{
|
||||
// Constructor: Set up your fixture.
|
||||
public DatabaseFixture()
|
||||
{
|
||||
// Initialize your test database or any other resources.
|
||||
}
|
||||
|
||||
// IDisposable implementation: Clean up your fixture.
|
||||
public void Dispose()
|
||||
{
|
||||
// Dispose of or release any resources used by your fixture.
|
||||
}
|
||||
}
|
1
active-allocator.Tests/GlobalUsings.cs
Normal file
1
active-allocator.Tests/GlobalUsings.cs
Normal file
@ -0,0 +1 @@
|
||||
global using Xunit;
|
29
active-allocator.Tests/MathTests.cs
Normal file
29
active-allocator.Tests/MathTests.cs
Normal file
@ -0,0 +1,29 @@
|
||||
namespace active_allocator.Tests;
|
||||
|
||||
public class MathTests
|
||||
{
|
||||
[Fact]
|
||||
public void PassingTest()
|
||||
{
|
||||
// Arrange
|
||||
int a = 2;
|
||||
int b = 2;
|
||||
|
||||
// Act
|
||||
int result = Add(2, 2);
|
||||
|
||||
// Assert
|
||||
Assert.Equal(4, result);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void FailingTest()
|
||||
{
|
||||
Assert.Equal(5, Add(2, 2));
|
||||
}
|
||||
|
||||
int Add(int x, int y)
|
||||
{
|
||||
return x + y;
|
||||
}
|
||||
}
|
30
active-allocator.Tests/active-allocator.Tests.csproj
Normal file
30
active-allocator.Tests/active-allocator.Tests.csproj
Normal file
@ -0,0 +1,30 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<RootNamespace>active_allocator.Tests</RootNamespace>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
|
||||
<IsPackable>false</IsPackable>
|
||||
<IsTestProject>true</IsTestProject>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.6.0" />
|
||||
<PackageReference Include="xunit" Version="2.4.2" />
|
||||
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="coverlet.collector" Version="6.0.0">
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\active-allocator\active-allocator.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/AutoMapper.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/AutoMapper.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/BCrypt.Net.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/BCrypt.Net.dll
Executable file
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Humanizer.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Humanizer.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.AspNetCore.Razor.Language.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.AspNetCore.Razor.Language.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.AspNetCore.SpaProxy.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.AspNetCore.SpaProxy.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Bcl.AsyncInterfaces.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Bcl.AsyncInterfaces.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Build.Framework.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Build.Framework.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Build.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Build.dll
Executable file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.CSharp.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.CSharp.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Elfie.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Elfie.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Features.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Features.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Razor.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Razor.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Scripting.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Scripting.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Workspaces.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.Workspaces.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.CodeAnalysis.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.DiaSymReader.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.DiaSymReader.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.DotNet.Scaffolding.Shared.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.DotNet.Scaffolding.Shared.dll
Executable file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.EntityFrameworkCore.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.EntityFrameworkCore.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.IdentityModel.Abstractions.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.IdentityModel.Abstractions.dll
Executable file
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.IdentityModel.Logging.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.IdentityModel.Logging.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.IdentityModel.Tokens.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.IdentityModel.Tokens.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.NET.StringTools.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.NET.StringTools.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.OpenApi.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.OpenApi.dll
Executable file
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.TestPlatform.CoreUtilities.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.TestPlatform.CoreUtilities.dll
Executable file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.TestPlatform.Utilities.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.TestPlatform.Utilities.dll
Executable file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Win32.SystemEvents.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Microsoft.Win32.SystemEvents.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Newtonsoft.Json.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Newtonsoft.Json.dll
Executable file
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Npgsql.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Npgsql.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Common.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Common.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Configuration.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Configuration.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.DependencyResolver.Core.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.DependencyResolver.Core.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Frameworks.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Frameworks.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.LibraryModel.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.LibraryModel.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Packaging.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Packaging.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.ProjectModel.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.ProjectModel.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Protocol.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Protocol.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Versioning.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/NuGet.Versioning.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Swashbuckle.AspNetCore.Swagger.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Swashbuckle.AspNetCore.Swagger.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Swashbuckle.AspNetCore.SwaggerGen.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Swashbuckle.AspNetCore.SwaggerGen.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/Swashbuckle.AspNetCore.SwaggerUI.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/Swashbuckle.AspNetCore.SwaggerUI.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.AttributedModel.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.AttributedModel.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.Convention.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.Convention.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.Hosting.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.Hosting.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.Runtime.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.Runtime.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.TypedParts.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Composition.TypedParts.dll
Executable file
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Drawing.Common.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Drawing.Common.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.IdentityModel.Tokens.Jwt.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.IdentityModel.Tokens.Jwt.dll
Executable file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Security.Permissions.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Security.Permissions.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Windows.Extensions.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/System.Windows.Extensions.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/active-allocator
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/active-allocator
Executable file
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
@ -0,0 +1,18 @@
|
||||
{
|
||||
"runtimeOptions": {
|
||||
"tfm": "net7.0",
|
||||
"frameworks": [
|
||||
{
|
||||
"name": "Microsoft.NETCore.App",
|
||||
"version": "7.0.0"
|
||||
},
|
||||
{
|
||||
"name": "Microsoft.AspNetCore.App",
|
||||
"version": "7.0.0"
|
||||
}
|
||||
],
|
||||
"configProperties": {
|
||||
"System.Reflection.NullabilityInfoContext.IsSupported": true
|
||||
}
|
||||
}
|
||||
}
|
7844
active-allocator.Tests/bin/Debug/net7.0/active-allocator.deps.json
Normal file
7844
active-allocator.Tests/bin/Debug/net7.0/active-allocator.deps.json
Normal file
File diff suppressed because it is too large
Load Diff
BIN
active-allocator.Tests/bin/Debug/net7.0/active-allocator.dll
Normal file
BIN
active-allocator.Tests/bin/Debug/net7.0/active-allocator.dll
Normal file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/active-allocator.pdb
Normal file
BIN
active-allocator.Tests/bin/Debug/net7.0/active-allocator.pdb
Normal file
Binary file not shown.
@ -0,0 +1,20 @@
|
||||
{
|
||||
"runtimeOptions": {
|
||||
"tfm": "net7.0",
|
||||
"includedFrameworks": [
|
||||
{
|
||||
"name": "Microsoft.NETCore.App",
|
||||
"version": "7.0.15"
|
||||
},
|
||||
{
|
||||
"name": "Microsoft.AspNetCore.App",
|
||||
"version": "7.0.15"
|
||||
}
|
||||
],
|
||||
"configProperties": {
|
||||
"System.GC.Server": true,
|
||||
"System.Reflection.NullabilityInfoContext.IsSupported": true,
|
||||
"System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false
|
||||
}
|
||||
}
|
||||
}
|
BIN
active-allocator.Tests/bin/Debug/net7.0/af/Humanizer.resources.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/af/Humanizer.resources.dll
Executable file
Binary file not shown.
@ -0,0 +1,10 @@
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft": "Warning",
|
||||
"Microsoft.AspNetCore.SpaProxy": "Information",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
}
|
||||
}
|
16
active-allocator.Tests/bin/Debug/net7.0/appsettings.json
Normal file
16
active-allocator.Tests/bin/Debug/net7.0/appsettings.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"ConnectionStrings": {
|
||||
"PSQLConnection": "Server=localhost;Port=15432;Database=aadb;User Id=postgres;Password=nqA3UV3CliLLHpLL"
|
||||
},
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Information",
|
||||
"Microsoft": "Warning",
|
||||
"Microsoft.Hosting.Lifetime": "Information"
|
||||
}
|
||||
},
|
||||
"AllowedHosts": "*",
|
||||
"AppSettings": {
|
||||
"Secret": "5de80277015f9fd564c4d1cc2cf827dbb1774cd66e7d79aa258d9c35a9f67f32fc6cf0dc24244242bd9501288e0fd69e315b"
|
||||
}
|
||||
}
|
BIN
active-allocator.Tests/bin/Debug/net7.0/ar/Humanizer.resources.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/ar/Humanizer.resources.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/az/Humanizer.resources.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/az/Humanizer.resources.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/bg/Humanizer.resources.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/bg/Humanizer.resources.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/bn-BD/Humanizer.resources.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/bn-BD/Humanizer.resources.dll
Executable file
Binary file not shown.
BIN
active-allocator.Tests/bin/Debug/net7.0/cs/Humanizer.resources.dll
Executable file
BIN
active-allocator.Tests/bin/Debug/net7.0/cs/Humanizer.resources.dll
Executable file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user