Tests: Move tests into package

This commit is contained in:
2024-01-05 17:21:12 +01:00
parent 2556033a07
commit 3a89e16db3
3 changed files with 6 additions and 6 deletions

View File

@ -0,0 +1,30 @@
using Elwig.Helpers;
using Microsoft.Data.Sqlite;
using System.Reflection;
namespace Tests.Helpers {
[TestFixture]
public class BillingTest {
private SqliteConnection? Connection;
[OneTimeSetUp]
public async Task SetupDatabase() {
Connection = await AppDbContext.ConnectAsync();
await AppDbContext.ExecuteEmbeddedScript(Connection, Assembly.GetExecutingAssembly(), "Tests.Resources.BillingInsert.sql");
}
[OneTimeTearDown]
public async Task TeardownDatabase() {
if (Connection == null) return;
await AppDbContext.ExecuteEmbeddedScript(Connection, Assembly.GetExecutingAssembly(), "Tests.Resources.BillingDelete.sql");
await Connection.DisposeAsync();
Connection = null;
}
[Test]
public void Test() {
// TODO
}
}
}