public void WhenScopeIsDisposedCreateScopeThrows() { var disposable = new Disposable(); var scope = new Scoped <Disposable>(disposable); scope.Dispose(); scope.Invoking(s => s.CreateLifetime()).Should().Throw <ObjectDisposedException>(); }