public void SetUp() { theContext = new SimpleTenantContext { CurrentTenant = Guid.NewGuid() }; thePolicy = new ByTenantStoragePolicy(theContext); }
public void SetUp() { inner = new EntityStorage <TrackedEntity>(new InMemoryPersistor()); theContext = new SimpleTenantContext { CurrentTenant = Guid.NewGuid() }; theStorage = new ByTenantEntityStorage <TrackedEntity>(inner, theContext); }
public void SetUp() { var container = new Container(new InMemoryPersistenceRegistry()); theContext = new SimpleTenantContext { CurrentTenant = Guid.NewGuid() }; container.Inject <ITenantContext>(theContext); thePersistor = container.GetInstance <IPersistor>(); theRepository = container.GetInstance <IEntityRepository>(); }
public void Execute <T>(Guid tenantId, Action <T> action) where T : class { Execute(SimpleTenantContext.ArgumentsForTenant(tenantId), action); }