public void DisposeRethrowsOnDelegateInvocationException()
        {
            // prepare
            var target = new DisposableOnce(() =>
            {
                throw new InvalidOperationException();
            });

            // execute
            target.Dispose();
        }
        public void DelegateIsCalledOnceDispose()
        {
            // prepare
            int disposed = 0;
            var target   = new DisposableOnce(() => disposed++);

            // execute
            target.Dispose();

            // verify
            Assert.AreEqual(1, disposed);
        }