using Microsoft.Data.Sqlite; using Microsoft.EntityFrameworkCore; using Observatory.Framework.Files.Journal; /// /// An in-memory database context for Pulsar. /// public class PulsarContext : DbContext { public SqliteConnection Connection { get; private set; } public DbSet Journals { get; set; } protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) { Connection = new SqliteConnection("Data Source=:memory:"); optionsBuilder.UseSqlite(Connection); } public override void Dispose() { Connection.Dispose(); base.Dispose(); } }