System.Transactions.Tests.TransactionScopeTest.TransactionScopeWithInvalidTimeSpanThrows C# (CSharp) Méthode

TransactionScopeWithInvalidTimeSpanThrows() private méthode

private TransactionScopeWithInvalidTimeSpanThrows ( ) : void
Résultat void
        public void TransactionScopeWithInvalidTimeSpanThrows()
        {
            Assert.Throws<ArgumentNullException>("transactionToUse", () => new TransactionScope(null, TimeSpan.FromSeconds(-1)));
            Assert.Throws<ArgumentOutOfRangeException>("scopeTimeout", () => new TransactionScope(TransactionScopeOption.Required, TimeSpan.FromSeconds(-1)));
        }