public void WaitUntilDbContextCreated(Action <DbContext> action)
        {
            var dbContext = DbContext();

            if (dbContext == null)
            {
                DbContextCreatedEvent += new OnDbContentCreated(action);
            }

            DbContextCreatedEvent?.Invoke(dbContext);
            action?.Invoke(dbContext);
        }
示例#2
0
 public void OnDbContextCreated(DbContext dbContext)
 {
     DbContextCreatedEvent?.Invoke(dbContext);
 }