[bcl] Remove more NET_2_0 checks from class libs
[mono.git] / mcs / class / corlib / Test / System.Security.Cryptography / CryptoStreamTest.cs
index 3ad6cce71f9c43393cee9af143f6f4349c908ea8..986a37780a5d449c3eaed72d46bfeea5e741a07c 100644 (file)
@@ -299,11 +299,7 @@ namespace MonoTests.System.Security.Cryptography {
 
                [Test]
                // LAMESPEC or MS BUG [ExpectedException (typeof (ObjectDisposedException))]
-#if NET_2_0
                [ExpectedException (typeof (NotSupportedException))]
-#else
-               [ExpectedException (typeof (ArgumentNullException))]
-#endif
                public void FlushFinalBlock_Disposed () 
                {
                        // do no corrupt writeStream in further tests
@@ -333,13 +329,8 @@ namespace MonoTests.System.Security.Cryptography {
 #if !NET_2_1
                [Test]
                // MS BUG [ExpectedException (typeof (ObjectDisposedException))]
-#if NET_2_0
                [Category ("NotWorking")]
                [ExpectedException (typeof (IndexOutOfRangeException))]
-#else
-               [Category ("NotDotNet")] // Test cause System.ExecutionEngineException on MS runtime
-               [ExpectedException (typeof (ArgumentNullException))] // should fail like previous test case
-#endif
                public void Read_Disposed_Break () 
                {
                        // do no corrupt readStream in further tests
@@ -437,13 +428,8 @@ namespace MonoTests.System.Security.Cryptography {
 #if !NET_2_1
                [Test]
                // MS BUG [ExpectedException (typeof (ObjectDisposedException))]
-#if NET_2_0
                [Category ("NotWorking")]
                [ExpectedException (typeof (IndexOutOfRangeException))]
-#else
-               [Category ("NotDotNet")] // Test cause System.ExecutionEngineException on MS runtime
-               [ExpectedException (typeof (ArgumentNullException))] // to match exception throw by Read in a similar case
-#endif
                public void Write_Disposed () 
                {
                        // do no corrupt writeStream in further tests
@@ -839,9 +825,7 @@ namespace MonoTests.System.Security.Cryptography {
                        Assert.AreEqual ("ximian", Encoding.Unicode.GetString (data, 0, len), "Unicode DES Roundtrip");
                }
 
-#if NET_2_0
                [Category ("NotWorking")]
-#endif         
                [Test]
                public void DecryptPartial_TransformFinalBlock_2Pass () 
                {
@@ -868,9 +852,7 @@ namespace MonoTests.System.Security.Cryptography {
                }
 
                // based on http://www.c-sharpcorner.com/Code/2002/May/FileEncryption.asp
-#if NET_2_0
                [Category ("NotWorking")]
-#endif 
                [Test]
                public void WriteByteReadByte () 
                {
@@ -1262,9 +1244,7 @@ namespace MonoTests.System.Security.Cryptography {
                        byte[] digest = hash.Hash;
                        Assert.AreEqual ("71-04-12-D1-95-01-CF-F9-8D-8F-F8-0D-F9-AA-11-7D", BitConverter.ToString (digest), "Hash");
                }
-#if NET_2_0
                [Category ("NotWorking")]
-#endif 
                [Test]
                public void CascadedCryptoStream_Read () 
                {
@@ -1385,10 +1365,8 @@ namespace MonoTests.System.Security.Cryptography {
                        WriteByte (PaddingMode.None, false);
                        WriteByte (PaddingMode.Zeros, false);
                        WriteByte (PaddingMode.PKCS7, true);    // related to bug #81597
-#if NET_2_0
                        WriteByte (PaddingMode.ANSIX923, true);
                        WriteByte (PaddingMode.ISO10126, true);
-#endif
                }
 
                [Test]