Sfoglia il codice sorgente

[bcl] Remove NET_4_0 defines from class libs

NET_4_0 is always defined now, so the ifdefs are redundant.
I verified the libs are exactly the same after this change, so this is effectively a no-op.
Alexander Köplinger 10 anni fa
parent
commit
98cf04084a
100 ha cambiato i file con 7 aggiunte e 947 eliminazioni
  1. 0 2
      mcs/class/Microsoft.Build.Engine/Test/Microsoft.Build.BuildEngine/TargetTest.cs
  2. 0 2
      mcs/class/Microsoft.Build.Tasks/Test/Microsoft.Build.Tasks/CodeTaskFactoryTest.cs
  3. 0 14
      mcs/class/Microsoft.Build.Tasks/Test/Microsoft.Build.Tasks/CscTest.cs
  4. 1 2
      mcs/class/Microsoft.Build.Utilities/Test/Microsoft.Build.Utilities/ToolLocationHelperTest.cs
  5. 0 2
      mcs/class/Mono.Parallel/Test/Mono.Collections.Concurrent/CollectionStressTestHelper.cs
  6. 0 2
      mcs/class/Mono.Parallel/Test/Mono.Collections.Concurrent/ConcurrentSkipListTests.cs
  7. 0 2
      mcs/class/Mono.Parallel/Test/Mono.Threading/ParallelTestHelper.cs
  8. 0 2
      mcs/class/Mono.Parallel/Test/Mono.Threading/SnziTests.cs
  9. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/AssociationAttributeTest.cs
  10. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/DisplayAttributeTest.cs
  11. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/EnumDataTypeAttributeTest.cs
  12. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/FilterUIHintAttributeTest.cs
  13. 0 45
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/RangeAttributeTest.cs
  14. 0 6
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/RegularExpressionAttributeTest.cs
  15. 0 4
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/RequiredAttributeTest.cs
  16. 0 14
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/StringLengthAttributeTest.cs
  17. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/UIHintAttributeTest.cs
  18. 0 109
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidationAttributeTest.cs
  19. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidationContextTest.cs
  20. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidationResultTest.cs
  21. 0 2
      mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidatorTest.cs
  22. 0 12
      mcs/class/System.Configuration/Test/System.Configuration/ConfigurationPermissionTest.cs
  23. 0 2
      mcs/class/System.Core/Test/System.IO.MemoryMappedFiles/MemoryMappedFileTest.cs
  24. 0 42
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest.cs
  25. 0 6
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_AddChecked.cs
  26. 0 7
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_AndAlso.cs
  27. 0 16
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Call.cs
  28. 0 6
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Convert.cs
  29. 0 12
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Equal.cs
  30. 0 14
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Lambda.cs
  31. 0 30
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_OrElse.cs
  32. 0 11
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Quote.cs
  33. 0 9
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_SubtractChecked.cs
  34. 0 9
      mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_TypeIs.cs
  35. 0 2
      mcs/class/System.Core/Test/System.Linq/EnumerableFixture.cs
  36. 0 2
      mcs/class/System.Core/Test/System.Linq/ParallelEnumerableTests.cs
  37. 0 2
      mcs/class/System.Core/Test/System.Linq/ParallelTestHelper.cs
  38. 0 2
      mcs/class/System.Core/Test/System.Runtime.CompilerServices/DynamicAttributeTest.cs
  39. 0 2
      mcs/class/System.Core/Test/System.Threading.Tasks/TaskExtensionsTests.cs
  40. 0 4
      mcs/class/System.Core/Test/System.Threading/ReaderWriterLockSlimTest.cs
  41. 0 2
      mcs/class/System.Data.Services/Test/System.Data.Services.Providers/DataServiceProviderMethodsTest.cs
  42. 0 2
      mcs/class/System.Data.Services/Test/System.Data.Services.Providers/ResourceTypeTest.cs
  43. 0 2
      mcs/class/System.Data/Test/System.Data/DataTableTest.cs
  44. 0 2
      mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/DataContractResolverTest.cs
  45. 0 2
      mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/XsdDataContractImporterTest2.cs
  46. 1 1
      mcs/class/System.ServiceModel.Web/System.ServiceModel.Web/WebOperationContext.cs
  47. 0 2
      mcs/class/System.ServiceModel.Web/Test/System.ServiceModel.Description/WebHttpBehaviorTest.cs
  48. 1 1
      mcs/class/System.ServiceModel.Web/Test/System.ServiceModel.Description/WebHttpEndpointTest.cs
  49. 2 2
      mcs/class/System.ServiceModel.Web/Test/System.ServiceModel.Web/WebOperationContextTest.cs
  50. 1 1
      mcs/class/System.ServiceModel/Assembly/AssemblyInfo.cs
  51. 0 5
      mcs/class/System.ServiceModel/Test/System.ServiceModel.Channels/HttpTransportBindingElementTest.cs
  52. 0 2
      mcs/class/System.ServiceModel/Test/System.ServiceModel.Channels/MsmqBindingElementBaseTest.cs
  53. 0 2
      mcs/class/System.ServiceModel/Test/System.ServiceModel.Configuration/StandardEndpointsSectionTest.cs
  54. 0 2
      mcs/class/System.ServiceModel/Test/System.ServiceModel.Description/ServiceMetadataEndpointTest.cs
  55. 0 2
      mcs/class/System.ServiceModel/Test/System.ServiceModel.Dispatcher/Bug652331_2Test.cs
  56. 0 2
      mcs/class/System.ServiceModel/Test/System.ServiceModel/ChannelFactory_1Test.cs
  57. 0 2
      mcs/class/System.ServiceModel/Test/System.ServiceModel/ClientBaseTest.cs
  58. 0 2
      mcs/class/System.ServiceModel/Test/System.ServiceModel/ServiceHostBaseTest.cs
  59. 0 31
      mcs/class/System.Web.Extensions/Test/System.Web.UI.WebControls/ListViewTest.cs
  60. 0 4
      mcs/class/System.Web.Routing/Test/System.Web.Routing/FakeHttpWorkerRequest.cs
  61. 0 6
      mcs/class/System.Web.Routing/Test/System.Web.Routing/RequestContext.cs
  62. 0 11
      mcs/class/System.Web.Routing/Test/System.Web.Routing/RouteCollectionTest.cs
  63. 0 18
      mcs/class/System.Web.Routing/Test/System.Web.Routing/RouteTest.cs
  64. 0 2
      mcs/class/System.Web.Routing/Test/System.Web.Routing/TestStubTypes.cs
  65. 0 75
      mcs/class/System.Web.Routing/Test/System.Web.Routing/UrlRoutingModuleTest.cs
  66. 0 5
      mcs/class/System.Web/System.Web.UI.WebControls/Table.cs
  67. 1 1
      mcs/class/System.Web/System.Web.Util/HttpEncoder.cs
  68. 0 1
      mcs/class/System.Web/System.Web_test.dll.sources
  69. 0 2
      mcs/class/System.Web/Test/System.Web.Caching/FileResponseElementTest.cs
  70. 0 2
      mcs/class/System.Web/Test/System.Web.Caching/HeaderElementTest.cs
  71. 0 2
      mcs/class/System.Web/Test/System.Web.Caching/MemoryResponseElementTest.cs
  72. 0 2
      mcs/class/System.Web/Test/System.Web.Caching/SqlCacheDependencyTest.cs
  73. 0 2
      mcs/class/System.Web/Test/System.Web.Caching/SubstitutionResponseElementTest.cs
  74. 0 2
      mcs/class/System.Web/Test/System.Web.Compilation/BuildManagerTest.cs
  75. 0 2
      mcs/class/System.Web/Test/System.Web.Compilation/BuildProviderTest.cs
  76. 0 2
      mcs/class/System.Web/Test/System.Web.Compilation/RouteUrlExpressionBuilderTest.cs
  77. 0 12
      mcs/class/System.Web/Test/System.Web.Configuration/MachineKeySectionTest.cs
  78. 0 20
      mcs/class/System.Web/Test/System.Web.Configuration/MachineKeyValidationConverterTest.cs
  79. 0 2
      mcs/class/System.Web/Test/System.Web.Security/MachineKeyTest.cs
  80. 0 4
      mcs/class/System.Web/Test/System.Web.UI.HtmlControls/HtmlFormTest.cs
  81. 0 5
      mcs/class/System.Web/Test/System.Web.UI.HtmlControls/HtmlInputButtonTest.cs
  82. 0 2
      mcs/class/System.Web/Test/System.Web.UI.WebControls.Adapters/MenuAdapterTest.cs
  83. 0 2
      mcs/class/System.Web/Test/System.Web.UI.WebControls/BaseDataBoundControlTest.cs
  84. 0 2
      mcs/class/System.Web/Test/System.Web.UI.WebControls/BaseDataListTest.cs
  85. 0 12
      mcs/class/System.Web/Test/System.Web.UI.WebControls/BoundFieldTest.cs
  86. 0 2
      mcs/class/System.Web/Test/System.Web.UI.WebControls/ChangePasswordTest.cs
  87. 0 20
      mcs/class/System.Web/Test/System.Web.UI.WebControls/CheckBoxFieldTest.cs
  88. 0 51
      mcs/class/System.Web/Test/System.Web.UI.WebControls/CheckBoxListTest.cs
  89. 0 4
      mcs/class/System.Web/Test/System.Web.UI.WebControls/CheckBoxTest.cs
  90. 0 1
      mcs/class/System.Web/Test/System.Web.UI.WebControls/DataGridTest.cs
  91. 0 2
      mcs/class/System.Web/Test/System.Web.UI.WebControls/DataKeyTest.cs
  92. 0 16
      mcs/class/System.Web/Test/System.Web.UI.WebControls/DataListItemTest.cs
  93. 0 2
      mcs/class/System.Web/Test/System.Web.UI.WebControls/DataListTest.cs
  94. 0 4
      mcs/class/System.Web/Test/System.Web.UI.WebControls/DataSourceControlTest.cs
  95. 0 56
      mcs/class/System.Web/Test/System.Web.UI.WebControls/DetailsViewTest.cs
  96. 0 12
      mcs/class/System.Web/Test/System.Web.UI.WebControls/EditCommandColumnTest.cs
  97. 0 44
      mcs/class/System.Web/Test/System.Web.UI.WebControls/FormViewTest.cs
  98. 0 38
      mcs/class/System.Web/Test/System.Web.UI.WebControls/GridViewTest.cs
  99. 0 12
      mcs/class/System.Web/Test/System.Web.UI.WebControls/HyperLinkTest.cs
  100. 0 4
      mcs/class/System.Web/Test/System.Web.UI.WebControls/ImageButtonTest.cs

+ 0 - 2
mcs/class/Microsoft.Build.Engine/Test/Microsoft.Build.BuildEngine/TargetTest.cs

@@ -905,7 +905,6 @@ namespace MonoTests.Microsoft.Build.BuildEngine {
 			Assert.AreEqual (0, logger.NormalMessageCount, "Unexpected extra messages found");
 		}
 
-#if NET_4_0
 		[Test]
 		[Category ("NotDotNet")]
 		public void TestBeforeAndAfterTargets ()
@@ -960,7 +959,6 @@ namespace MonoTests.Microsoft.Build.BuildEngine {
 			//warnings for referencing unknown targets: NonExistant and Foo
 			Assert.AreEqual (2, logger.WarningsCount, "Expected warnings not raised");
 		}
-#endif
 
 		[Test]
 		public void TestTargetReturns ()

+ 0 - 2
mcs/class/Microsoft.Build.Tasks/Test/Microsoft.Build.Tasks/CodeTaskFactoryTest.cs

@@ -25,7 +25,6 @@
 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
-#if NET_4_0
 using System;
 using System.IO;
 using System.Linq;
@@ -207,4 +206,3 @@ Log.LogWarning(""Color: "" + System.Drawing.Color.CornflowerBlue);
 	}
 }
 
-#endif

+ 0 - 14
mcs/class/Microsoft.Build.Tasks/Test/Microsoft.Build.Tasks/CscTest.cs

@@ -44,20 +44,6 @@ namespace MonoTests.Microsoft.Build.Tasks {
 		public void ARFC (CommandLineBuilderExtension commandLine)
 		{
 			base.AddResponseFileCommands (commandLine);
-#if !NET_4_0
-			string s = commandLine.ToString ();
-			if (s.Length == 6)
-				Assert.AreEqual ("/sdk:2", s);
-			else
-				Assert.AreEqual ("/sdk:2 ", s.Substring (0, 7));
-
-			BindingFlags flags = BindingFlags.Instance | BindingFlags.NonPublic;
-			PropertyInfo pi = typeof (CommandLineBuilderExtension).GetProperty ("CommandLine", flags);
-			System.Text.StringBuilder sb = (System.Text.StringBuilder) pi.GetValue (commandLine, null);
-			sb.Length = 0;
-			if (s.Length > 6)
-				sb.Append (s.Substring (7));
-#endif
 		}
 
 		public void ACLC (CommandLineBuilderExtension commandLine)

+ 1 - 2
mcs/class/Microsoft.Build.Utilities/Test/Microsoft.Build.Utilities/ToolLocationHelperTest.cs

@@ -1,4 +1,4 @@
-#if NET_4_0
+
 using System;
 using NUnit.Framework;
 using Microsoft.Build.Utilities;
@@ -18,4 +18,3 @@ namespace MonoTests.Microsoft.Build.Utilities
 	}
 }
 
-#endif

+ 0 - 2
mcs/class/Mono.Parallel/Test/Mono.Collections.Concurrent/CollectionStressTestHelper.cs

@@ -1,4 +1,3 @@
-#if NET_4_0
 // 
 // CollectionStressTestHelper.cs
 //  
@@ -126,4 +125,3 @@ namespace MonoTests.Mono.Collections.Concurrent
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/Mono.Parallel/Test/Mono.Collections.Concurrent/ConcurrentSkipListTests.cs

@@ -1,4 +1,3 @@
-#if NET_4_0
 // ConcurrentSkipListTests.cs
 //
 // Copyright (c) 2008 Jérémie "Garuma" Laval
@@ -110,4 +109,3 @@ namespace MonoTests.Mono.Collections.Concurrent
 		 
 	}
 }
-#endif

+ 0 - 2
mcs/class/Mono.Parallel/Test/Mono.Threading/ParallelTestHelper.cs

@@ -1,4 +1,3 @@
-#if NET_4_0
 // TestHelper.cs
 //
 // Copyright (c) 2008 Jérémie "Garuma" Laval
@@ -86,4 +85,3 @@ namespace MonoTests.Mono.Threading.Tasks
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/Mono.Parallel/Test/Mono.Threading/SnziTests.cs

@@ -1,4 +1,3 @@
-#if NET_4_0
 // 
 // SnziTests.cs
 //  
@@ -135,4 +134,3 @@ namespace MonoTests.Mono.Threading
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/AssociationAttributeTest.cs

@@ -35,7 +35,6 @@ using NUnit.Framework;
 
 namespace MonoTests.System.ComponentModel.DataAnnotations
 {
-#if NET_4_0
 	[TestFixture]
 	public class AssociationAttributeTest
 	{
@@ -125,5 +124,4 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Assert.AreEqual (String.Empty, list [0], "#C4-2");
 		}
 	}
-#endif
 }

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/DisplayAttributeTest.cs

@@ -8,7 +8,6 @@ using System.Reflection;
 
 namespace MonoTests.System.ComponentModel.DataAnnotations
 {
-#if NET_4_0
 	public class AttributeTargetValidation
 	{
 		[Display(ResourceType = typeof(GoodResources), Name = "NameKey")]
@@ -274,5 +273,4 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Assert.Fail();
 		}
 	}
-#endif
 }

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/EnumDataTypeAttributeTest.cs

@@ -35,7 +35,6 @@ using NUnit.Framework;
 
 namespace MonoTests.System.ComponentModel.DataAnnotations
 {
-#if NET_4_0
 	[TestFixture]
 	public class EnumDataTypeAttributeTest
 	{
@@ -133,5 +132,4 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 		Five = 8,
 		Six = 16
 	}
-#endif
 }

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/FilterUIHintAttributeTest.cs

@@ -5,7 +5,6 @@
 
 // https://silverlight.svn.codeplex.com/svn/Release/Silverlight4/Source/RiaClient.Tests/System.ComponentModel.DataAnnotations/FilterUIHintAttributeTest.cs
 
-#if NET_4_0
 
 using System;
 using System.ComponentModel;
@@ -90,4 +89,3 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
     }
 }
 
-#endif

+ 0 - 45
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/RangeAttributeTest.cs

@@ -104,26 +104,16 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 
 			Assert.IsNotNull (attr.Minimum, "#A1-1");
 			Assert.IsNotNull (attr.Maximum, "#A1-2");
-#if NET_4_0
 			Assert.AreEqual (typeof (string), attr.Minimum.GetType (), "#A2-1");
 			Assert.AreEqual (typeof (string), attr.Maximum.GetType (), "#A2-2");
 			Assert.AreEqual ("-10", attr.Minimum, "#A3-1");
 			Assert.AreEqual ("10", attr.Maximum, "#A3-2");
-#else
-			Assert.AreEqual (typeof (int), attr.Minimum.GetType (), "#A2-1");
-			Assert.AreEqual (typeof (int), attr.Maximum.GetType (), "#A2-2");
-			Assert.AreEqual (-10, attr.Minimum, "#A3-1");
-			Assert.AreEqual (10, attr.Maximum, "#A3-2");
-#endif
 			Assert.IsNotNull (attr.OperandType, "#A4-1");
 			Assert.AreEqual (typeof (int), attr.OperandType, "#A4-2");
 		}
 
 		[Test]
 		//LAMESPEC: documented to throw
-#if !NET_4_0
-		[ExpectedException (typeof (ArgumentNullException))]
-#endif
 		public void Constructor_Type_String_String_Null_Type ()
 		{
 			var attr = new DA.RangeAttribute (null, "-10", "10");
@@ -144,7 +134,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 				attr.IsValid ("zero");
 			}, "#A1-5");
 			Assert.IsTrue (attr.IsValid (null), "#A1-6");
-#if NET_4_0
 			attr = new DA.RangeAttribute (typeof (int), "minus ten", "ten");
 			AssertExtensions.Throws<Exception> (() => {
 				attr.IsValid ("0");
@@ -196,31 +185,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			attr.IsValid (12);
 			Assert.AreEqual (typeof (int), attr.Minimum.GetType (), "#A7-1");
 			Assert.AreEqual (typeof (int), attr.Maximum.GetType (), "#A7-2");
-#else
-			AssertExtensions.Throws<Exception> (() => {
-				attr = new DA.RangeAttribute (typeof (int), "minus ten", "ten");
-			}, "#A2");
-
-			AssertExtensions.Throws<ArgumentException> (() => {
-				attr = new DA.RangeAttribute (typeof (RangeAttributeTest), "-10", "10");
-			}, "#A3");
-
-			AssertExtensions.Throws<ArgumentNullException> (() => {
-				attr = new DA.RangeAttribute (null, "-10", "10");
-			}, "#A4");
-
-			AssertExtensions.Throws<NotSupportedException> (() => {
-				attr = new DA.RangeAttribute (typeof (int), null, "10");
-			}, "#A5-1");
-
-			AssertExtensions.Throws<NotSupportedException> (() => {
-				attr = new DA.RangeAttribute (typeof (int), "10", null);
-			}, "#A5-2");
-
-			attr = new DA.RangeAttribute (typeof (int), "-10", "10");
-			Assert.AreEqual (typeof (int), attr.Minimum.GetType (), "#A6-1");
-			Assert.AreEqual (typeof (int), attr.Maximum.GetType (), "#A6-2");
-#endif
 		}
 
 		[Test]
@@ -232,19 +196,10 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 
 			attr.ErrorMessage = "Param 0: {0}";
 			Assert.AreEqual ("Param 0: MyField", attr.FormatErrorMessage ("MyField"), "#A2-1");
-#if !NET_4_0
-			attr = new DA.RangeAttribute (-10, 10);
-#endif
 			attr.ErrorMessage = "Param 0: {0}; Param 1: {1}";
 			Assert.AreEqual ("Param 0: MyField; Param 1: -10", attr.FormatErrorMessage ("MyField"), "#A2-2");
-#if !NET_4_0
-			attr = new DA.RangeAttribute (-10, 10);
-#endif
 			attr.ErrorMessage = "Param 0: {0}; Param 1: {1}; Param 2: {2}";
 			Assert.AreEqual ("Param 0: MyField; Param 1: -10; Param 2: 10", attr.FormatErrorMessage ("MyField"), "#A2-3");
-#if !NET_4_0
-			attr = new DA.RangeAttribute (-10, 10);
-#endif
 			attr.ErrorMessage = "Param 0: {0}; Param 1: {1}; Param 2: {2}; Param 3: {3}";
 			AssertExtensions.Throws<FormatException> (() => {
 				attr.FormatErrorMessage ("MyField");

+ 0 - 6
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/RegularExpressionAttributeTest.cs

@@ -68,15 +68,9 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 				rea.FormatErrorMessage ("MyField"), 
 				"Error message not correctly formatted.");
 
-#if !NET_4_0
-			rea = new RegularExpressionAttributePoker (@"[A-Za-z]");
-#endif
 			rea.ErrorMessage = "Param 0: {0}";
 			Assert.AreEqual ("Param 0: MyField", rea.FormatErrorMessage ("MyField"), "Error message not correctly updated.");
 
-#if !NET_4_0
-			rea = new RegularExpressionAttributePoker (@"[A-Za-z]");
-#endif
 			rea.ErrorMessage = "Param 0: {0}; Param 1: {1}";
 			Assert.AreEqual ("Param 0: MyField; Param 1: [A-Za-z]", rea.FormatErrorMessage ("MyField"), "Error message not correctly updated.");
 			Assert.AreEqual ("Param 0: ; Param 1: [A-Za-z]", rea.FormatErrorMessage (null), "Error message fails on null value.");

+ 0 - 4
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/RequiredAttributeTest.cs

@@ -45,12 +45,9 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Assert.IsFalse (attr.IsValid (String.Empty), "#A2");
 			Assert.IsTrue (attr.IsValid ("string"), "#A3");
 			Assert.IsTrue (attr.IsValid (1), "#A4");
-#if NET_4_0
 			attr.AllowEmptyStrings = true;
 			Assert.IsTrue (attr.IsValid (String.Empty), "#A5");
-#endif
 		}
-#if NET_4_0
 		[Test]
 		public void AllowEmptyStrings ()
 		{
@@ -60,6 +57,5 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			attr.AllowEmptyStrings = true;
 			Assert.IsTrue (attr.AllowEmptyStrings, "#A2");
 		}
-#endif
 	}
 }

+ 0 - 14
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/StringLengthAttributeTest.cs

@@ -58,16 +58,10 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Assert.AreEqual (10, sla.MaximumLength, "#A1-1");
 			Assert.AreEqual (null, sla.ErrorMessage, "#A1-2");
 			Assert.AreEqual ("The field {0} must be a string with a maximum length of {1}.", sla.GetErrorMessageString (), "#A1-3");
-#if NET_4_0
 			Assert.AreEqual (0, sla.MinimumLength, "#A1-4");
 
 			sla = new StringLengthAttributePoker (-10);
 			Assert.AreEqual (-10, sla.MaximumLength, "#B1");
-#else
-			AssertExtensions.Throws<ArgumentOutOfRangeException> (() => {
-				sla = new StringLengthAttributePoker (-10);
-			}, "#B1");
-#endif
 			sla = new StringLengthAttributePoker (0);
 			Assert.AreEqual (0, sla.MaximumLength, "#C1");
 		}
@@ -78,14 +72,8 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			var sla = new StringLengthAttributePoker (10);
 
 			Assert.AreEqual ("The field MyField must be a string with a maximum length of 10.", sla.FormatErrorMessage ("MyField"), "#A1-1");
-#if !NET_4_0
-			sla = new StringLengthAttributePoker (10);
-#endif
 			sla.ErrorMessage = "Param 0: {0}";
 			Assert.AreEqual ("Param 0: MyField", sla.FormatErrorMessage ("MyField"), "#A1-2");
-#if !NET_4_0
-			sla = new StringLengthAttributePoker (10);
-#endif
 			sla.ErrorMessage = "Param 0: {0}; Param 1: {1}";
 			Assert.AreEqual ("Param 0: MyField; Param 1: 10", sla.FormatErrorMessage ("MyField"), "#A1-2");
 			Assert.AreEqual ("Param 0: ; Param 1: 10", sla.FormatErrorMessage (null), "#A1-3");
@@ -112,7 +100,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Assert.IsTrue (sla.IsValid (null), "#B1-1");
 			Assert.IsTrue (sla.IsValid (String.Empty), "#B1-2");
 			Assert.IsFalse (sla.IsValid ("string"), "#B1-3");
-#if NET_4_0
 			sla = new StringLengthAttributePoker (-10);
 			AssertExtensions.Throws <InvalidOperationException> (() => {
 				sla.IsValid ("123");
@@ -127,7 +114,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			sla.MinimumLength = 5;
 			Assert.IsFalse (sla.IsValid ("123"), "#C2-1");
 			Assert.IsTrue (sla.IsValid ("12345"), "#C2-2");
-#endif
 		}
 	}
 }

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/UIHintAttributeTest.cs

@@ -5,7 +5,6 @@
 
 // https://silverlight.svn.codeplex.com/svn/Release/Silverlight4/Source/RiaClient.Tests/System.ComponentModel.DataAnnotations/UIHintAttributeTest.cs
 
-#if NET_4_0
 
 using System;
 using System.ComponentModel;
@@ -136,4 +135,3 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
     }
 }
 
-#endif

+ 0 - 109
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidationAttributeTest.cs

@@ -89,46 +89,11 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 
 			attr.ErrorMessage = "Test";
 			Assert.AreEqual ("Test", attr.ErrorMessage, "#A2");
-#if NET_4_0
 			attr.ErrorMessage = String.Empty;
 			Assert.AreEqual (String.Empty, attr.ErrorMessage, "#A3");
 
 			attr.ErrorMessage = null;
 			Assert.IsNull (attr.ErrorMessage, "#A4");
-#else
-			try {
-				attr.ErrorMessage = String.Empty;
-				Assert.Fail ("#A3");
-			} catch (InvalidOperationException) {
-				// success
-			}
-
-			attr = new ValidateFooAttribute ("Test");
-			try {
-				attr.ErrorMessage = null;
-				Assert.Fail ("#A4");
-			} catch (ArgumentException) {
-				// success
-			}
-
-			attr = new ValidateFooAttribute ("Test");
-			try {
-				attr.ErrorMessage = String.Empty;
-				Assert.Fail ("#A4");
-			} catch (ArgumentException) {
-				// success
-			}
-
-			attr = new ValidateFooAttribute ();
-			attr.ErrorMessageResourceName = "ErrorProperty1";
-
-			try {
-				attr.ErrorMessage = "Test Message";
-				Assert.Fail ("#E1");
-			} catch (InvalidOperationException) {
-				// success
-			}
-#endif
 			
 		}
 
@@ -142,47 +107,12 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			attr.ErrorMessageResourceName = "Test";
 			Assert.IsNotNull (attr.ErrorMessageResourceName, "#A2-1");
 			Assert.AreEqual ("Test", attr.ErrorMessageResourceName, "#A2-2");
-#if NET_4_0
 			attr.ErrorMessageResourceName = String.Empty;
 			Assert.IsNotNull (attr.ErrorMessageResourceName, "#A3-1");
 			Assert.AreEqual (String.Empty, attr.ErrorMessageResourceName, "#A3-2");
 
 			attr.ErrorMessageResourceName = null;
 			Assert.IsNull (attr.ErrorMessageResourceName, "#A3-1");
-#else
-			try {
-				attr.ErrorMessageResourceName = String.Empty;
-				Assert.Fail ("#A3-1");
-			} catch (InvalidOperationException) {
-				// success
-			}
-
-			attr = new ValidateFooAttribute ("Test");
-			try {
-				attr.ErrorMessageResourceName = String.Empty;
-				Assert.Fail ("#A3-2");
-			} catch (ArgumentException) {
-				// success
-			}
-
-			attr = new ValidateFooAttribute ("Test");
-			try {
-				attr.ErrorMessageResourceName = null;
-				Assert.Fail ("#A3-3");
-			} catch (ArgumentException) {
-				// success
-			}
-
-			attr = new ValidateFooAttribute ();
-			attr.ErrorMessageResourceType = typeof (FooErrorMessageProvider);
-
-			try {
-				attr.ErrorMessageResourceName = "NoSuchProperty";
-				Assert.Fail ("#A3-4");
-			} catch (InvalidOperationException) {
-				// success
-			}
-#endif
 		}
 
 		[Test]
@@ -195,17 +125,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			attr.ErrorMessageResourceType = typeof (FooErrorMessageProvider);
 			Assert.IsNotNull (attr.ErrorMessageResourceType, "#A2-1");
 			Assert.AreEqual (typeof (FooErrorMessageProvider), attr.ErrorMessageResourceType, "#A2-2");
-#if !NET_4_0
-			attr = new ValidateFooAttribute ();
-			attr.ErrorMessageResourceName = "NoSuchProperty";
-			
-			try {
-				attr.ErrorMessageResourceType = typeof (FooErrorMessageProvider);
-				Assert.Fail ("#A3");
-			} catch (InvalidOperationException) {
-				// success
-			}
-#endif
 		}
 
 		[Test]
@@ -224,7 +143,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			} catch (InvalidOperationException) {
 				// success
 			}
-#if NET_4_0
 			attr = new ValidateFooAttribute ();
 			attr.ErrorMessageResourceName = String.Empty;
 			try {
@@ -324,7 +242,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			} catch (InvalidOperationException) {
 				// success
 			}
-#endif
 
 			attr = new ValidateFooAttribute ();
 			attr.ErrorMessageResourceName = "ErrorProperty1";
@@ -341,7 +258,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			attr.ErrorMessageResourceType = typeof (FooErrorMessageProvider);
 			Assert.IsNotNull (attr.GetErrorMessageString (), "#D1-3");
 			Assert.AreEqual ("Error Message 1", attr.GetErrorMessageString (), "#D1-4");
-#if NET_4_0
 			attr.ErrorMessage = "Test Message";
 			try {
 				attr.GetErrorMessageString ();
@@ -349,7 +265,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			} catch (InvalidOperationException) {
 				// success
 			}
-#endif
 		}
 
 		[Test]
@@ -363,31 +278,20 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			attr.ErrorMessage = "Test: {0}";
 			Assert.IsNotNull (attr.FormatErrorMessage ("SomeField"), "#A2-1");
 			Assert.AreEqual ("Test: SomeField", attr.FormatErrorMessage ("SomeField"), "#A2-2");
-#if !NET_4_0
-			attr = new ValidateFooAttribute ();
-#else
 			attr.ErrorMessage = null;
-#endif
 			attr.ErrorMessageResourceName = "ErrorProperty1";
 			attr.ErrorMessageResourceType = typeof (FooErrorMessageProvider);
 			Assert.IsNotNull (attr.FormatErrorMessage ("SomeField"), "#B1-1");
 			Assert.AreEqual ("Error Message 1", attr.FormatErrorMessage ("SomeField"), "#B1-2");
-#if !NET_4_0
-			attr = new ValidateFooAttribute ();
-#endif
 			attr.ErrorMessageResourceName = "ErrorProperty6";
 			attr.ErrorMessageResourceType = typeof (FooErrorMessageProvider);
 			Assert.IsNotNull (attr.FormatErrorMessage ("SomeField"), "#B2-1");
 			Assert.AreEqual ("Error Message 6: SomeField", attr.FormatErrorMessage ("SomeField"), "#B2-2");
-#if !NET_4_0
-			attr = new ValidateFooAttribute ();
-#endif
 			attr.ErrorMessageResourceName = "ErrorProperty6";
 			attr.ErrorMessageResourceType = typeof (FooErrorMessageProvider);
 			Assert.IsNotNull (attr.FormatErrorMessage ("SomeField"), "#B3-1");
 			Assert.AreEqual ("Error Message 6: ", attr.FormatErrorMessage (null), "#B3-2");
 		}
-#if NET_4_0
 		[Test]
 		public void GetValidationResult ()
 		{
@@ -556,7 +460,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Assert.AreEqual ("bool IsValid (object value)", attr.Calls [1], "#A2-3");
 			Assert.AreEqual ("string FormatErrorMessage (string name)", attr.Calls [2], "#A2-4");
 		}
-#endif
 		[Test]
 		public void Validate_Object_String ()
 		{
@@ -593,12 +496,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 		{
 			return ErrorMessageString;
 		}
-#if !NET_4_0
-		public override bool IsValid (object value)
-		{
-			return value != null;
-		}
-#endif
 	}
 
 	class ValidateBarAttribute : ValidateFooAttribute
@@ -613,7 +510,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 		{
 			return value != null;
 		}
-#if NET_4_0
 		protected override ValidationResult IsValid (object value, ValidationContext validationContext)
 		{
 			if (!IsValid (value))
@@ -625,7 +521,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 		{
 			return base.IsValid (value, validationContext);
 		}
-#endif
 	}
 
 	class ValidateBazAttribute : ValidateBarAttribute
@@ -637,20 +532,17 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Calls.Add ("bool IsValid (object value)");
 			return base.IsValid (value);
 		}
-#if NET_4_0
 		protected override ValidationResult IsValid (object value, ValidationContext validationContext)
 		{
 			Calls.Add ("ValidationResult IsValid (object value, ValidationContext validationContext)");
 			return base.IsValid (value, validationContext);
 		}
-#endif
 		public override string FormatErrorMessage (string name)
 		{
 			Calls.Add ("string FormatErrorMessage (string name)");
 			return base.FormatErrorMessage (name);
 		}
 	}
-#if NET_4_0
 	class ValidateSomethingAttribute : ValidationAttribute
 	{
 		public override bool IsValid (object value)
@@ -670,7 +562,6 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			return IsValid (value, validationContext);
 		}
 	}
-#endif
 	class FooErrorMessageProvider
 	{
 		public static string ErrorProperty1

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidationContextTest.cs

@@ -35,7 +35,6 @@ using NUnit.Framework;
 
 namespace MonoTests.System.ComponentModel.DataAnnotations
 {
-#if NET_4_0
 	[TestFixture]
 	public class ValidationContextTest
 	{
@@ -238,5 +237,4 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			return null;
 		}
 	}
-#endif
 }

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidationResultTest.cs

@@ -35,7 +35,6 @@ using NUnit.Framework;
 
 namespace MonoTests.System.ComponentModel.DataAnnotations
 {
-#if NET_4_0
 	[TestFixture]
 	public class ValidationResultTest
 	{
@@ -93,5 +92,4 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			Assert.IsNull (success, "#A1");
 		}
 	}
-#endif
 }

+ 0 - 2
mcs/class/System.ComponentModel.DataAnnotations/Test/System.ComponentModel.DataAnnotations/ValidatorTest.cs

@@ -33,7 +33,6 @@ using MonoTests.Common;
 
 namespace MonoTests.System.ComponentModel.DataAnnotations
 {
-#if NET_4_0
 	[TestFixture]
 	public class ValidatorTest
 	{
@@ -1233,5 +1232,4 @@ namespace MonoTests.System.ComponentModel.DataAnnotations
 			}
 		}
 	}
-#endif
 }

+ 0 - 12
mcs/class/System.Configuration/Test/System.Configuration/ConfigurationPermissionTest.cs

@@ -143,27 +143,15 @@ namespace MonoTests.System.Configuration {
 		{
 			ConfigurationPermission p = new ConfigurationPermission (PermissionState.Unrestricted);
 
-#if NET_4_0
 			Assert.AreEqual(
 					"<IPermission class=\"System.Configuration.ConfigurationPermission, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a\"\nversion=\"1\"\nUnrestricted=\"true\"/>\n",
 					p.ToString().Replace ("\r\n", "\n"), "A1");
-#else
-			Assert.AreEqual (
-					"<IPermission class=\"System.Configuration.ConfigurationPermission, System.Configuration, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a\"\nversion=\"1\"\nUnrestricted=\"true\"/>\n",
-					p.ToString ().Replace ("\r\n", "\n"), "A1");
-#endif
 
 			p = new ConfigurationPermission (PermissionState.None);
 
-#if NET_4_0
 			Assert.AreEqual (
 					 "<IPermission class=\"System.Configuration.ConfigurationPermission, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a\"\nversion=\"1\"/>\n",
 					 p.ToString().Replace ("\r\n", "\n"), "A2");
-#else
-			Assert.AreEqual (
-					 "<IPermission class=\"System.Configuration.ConfigurationPermission, System.Configuration, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a\"\nversion=\"1\"/>\n",
-					 p.ToString ().Replace ("\r\n", "\n"), "A2");
-#endif
 		}
 	}
 }

+ 0 - 2
mcs/class/System.Core/Test/System.IO.MemoryMappedFiles/MemoryMappedFileTest.cs

@@ -26,7 +26,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_4_0
 
 using System;
 using System.IO;
@@ -411,5 +410,4 @@ namespace MonoTests.System.IO.MemoryMappedFiles {
 	}
 }
 
-#endif
 

+ 0 - 42
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest.cs

@@ -133,9 +133,6 @@ namespace MonoTests.System.Linq.Expressions {
 			var p = Expression.Parameter (typeof (string), null);
 			Assert.AreEqual (null, p.Name);
 			Assert.AreEqual (typeof (string), p.Type);
-#if !NET_4_0
-			Assert.AreEqual ("<param>", p.ToString ());
-#endif
 		}
 
 		[Test]
@@ -144,9 +141,6 @@ namespace MonoTests.System.Linq.Expressions {
 			var p = Expression.Parameter (typeof (string), "");
 			Assert.AreEqual ("", p.Name);
 			Assert.AreEqual (typeof (string), p.Type);
-#if !NET_4_0
-			Assert.AreEqual ("", p.ToString ());
-#endif
 		}
 
 		[Test]
@@ -199,9 +193,6 @@ namespace MonoTests.System.Linq.Expressions {
 
 			Assert.AreEqual (typeof (Func<string, string>), identity.GetType ());
 			Assert.IsNotNull (identity.Target);
-#if !NET_4_0
-			Assert.AreEqual (typeof (ExecutionScope), identity.Target.GetType ());
-#endif
 		}
 
 		class Foo {
@@ -217,39 +208,6 @@ namespace MonoTests.System.Linq.Expressions {
 			}
 		}
 
-#if !NET_4_0
-		[Test]
-		public void GlobalsInScope ()
-		{
-			var foo = new Foo { gazonk = "gazonk" };
-			var bar = new Bar { baz = 42 };
-
-			var l = Expression.Lambda<Func<string>> (
-				Expression.Call (
-					typeof (string).GetMethod ("Concat", new [] { typeof (string), typeof (string) }),
-					Expression.Field (Expression.Constant (foo), typeof (Foo).GetField ("gazonk")),
-					Expression.Call (Expression.Constant (bar), typeof (Bar).GetMethod ("ToString"))));
-
-			var del = l.Compile ();
-
-			var scope = del.Target as ExecutionScope;
-
-			Assert.IsNotNull (scope);
-
-			var globals = scope.Globals;
-
-			Assert.IsNotNull (globals);
-
-			Assert.AreEqual (2, globals.Length);
-			Assert.AreEqual (typeof (StrongBox<Foo>), globals [0].GetType ());
-			Assert.AreEqual (typeof (StrongBox<Bar>), globals [1].GetType ());
-
-			Assert.AreEqual (foo, ((StrongBox<Foo>) globals [0]).Value);
-			Assert.AreEqual (bar, ((StrongBox<Bar>) globals [1]).Value);
-
-			Assert.AreEqual ("gazonk42", del ());
-		}
-#endif
 
 		[Test]
 		public void SimpleHoistedParameter ()

+ 0 - 6
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_AddChecked.cs

@@ -194,12 +194,6 @@ namespace MonoTests.System.Linq.Expressions
 			// These are invalid:
 			InvalidOperation<byte> (Byte.MaxValue, 2);
 			InvalidOperation<sbyte> (SByte.MaxValue, 2);
-#if !NET_4_0
-			// Stuff that just fits in 32 bits, does not overflow:
-			MustNotOverflow<short> (Int16.MaxValue, 2);
-			MustNotOverflow<short> (Int16.MaxValue, 2);
-			MustNotOverflow<ushort> (UInt16.MaxValue, 2);
-#endif
 			// Doubles, floats, do not overflow
 			MustNotOverflow<float> (Single.MaxValue, 1);
 			MustNotOverflow<double> (Double.MaxValue, 1);

+ 0 - 7
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_AndAlso.cs

@@ -80,9 +80,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (ExpressionType.AndAlso, expr.NodeType, "AndAlso#01");
 			Assert.AreEqual (typeof (bool), expr.Type, "AndAlso#02");
 			Assert.IsNull (expr.Method, "AndAlso#03");
-#if !NET_4_0
-			Assert.AreEqual ("(True && False)", expr.ToString(), "AndAlso#04");
-#endif
 		}
 
 		[Test]
@@ -97,10 +94,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (typeof (OpClass), expr.Type, "AndAlso#06");
 			Assert.AreEqual (mi, expr.Method, "AndAlso#07");
 			Assert.AreEqual ("op_BitwiseAnd", expr.Method.Name, "AndAlso#08");
-#if !NET_4_0
-			Assert.AreEqual ("(value(MonoTests.System.Linq.Expressions.OpClass) && value(MonoTests.System.Linq.Expressions.OpClass))",
-				expr.ToString(), "AndAlso#09");
-#endif
 		}
 
 		[Test]

+ 0 - 16
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Call.cs

@@ -87,11 +87,7 @@ namespace MonoTests.System.Linq.Expressions {
 		}
 
 		[Test]
-#if NET_4_0
 		[ExpectedException (typeof (ArgumentException))]
-#else
-		[ExpectedException (typeof (ArgumentNullException))]
-#endif
 		public void ArgInstanceNullForNonStaticMethod ()
 		{
 			Expression.Call (null, typeof (object).GetMethod ("ToString"));
@@ -292,18 +288,6 @@ namespace MonoTests.System.Linq.Expressions {
 		{
 			return (int) (i as ConstantExpression).Value;
 		}
-#if !NET_4_0 // dlr bug 5875
-		[Test]
-		public void CallMethodWithExpressionParameter ()
-		{
-			var call = Expression.Call (GetType ().GetMethod ("Bang"), Expression.Constant (42));
-			Assert.AreEqual (ExpressionType.Quote, call.Arguments [0].NodeType);
-
-			var l = Expression.Lambda<Func<int>> (call).Compile ();
-
-			Assert.AreEqual (42, l ());
-		}
-#endif
 		static bool fout_called = false;
 
 		public static int FooOut (out int x)

+ 0 - 6
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Convert.cs

@@ -81,16 +81,10 @@ namespace MonoTests.System.Linq.Expressions {
 
 			var conv = Expression.Convert (p, typeof (ITzap));
 			Assert.AreEqual (typeof (ITzap), conv.Type);
-#if !NET_4_0
-			Assert.AreEqual ("Convert(<param>)", conv.ToString ());
-#endif
 			p = Expression.Parameter (typeof (ITzap), null);
 			conv = Expression.Convert (p, typeof (IFoo));
 
 			Assert.AreEqual (typeof (IFoo), conv.Type);
-#if !NET_4_0
-			Assert.AreEqual ("Convert(<param>)", conv.ToString ());
-#endif
 		}
 
 		[Test]

+ 0 - 12
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Equal.cs

@@ -76,9 +76,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (ExpressionType.Equal, expr.NodeType);
 			Assert.AreEqual (typeof (bool), expr.Type);
 			Assert.IsNull (expr.Method);
-#if !NET_4_0
-			Assert.AreEqual ("(1 = 2)", expr.ToString ());
-#endif
 		}
 
 		[Test]
@@ -107,9 +104,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (true, expr.IsLifted);
 			Assert.AreEqual (false, expr.IsLiftedToNull);
 			Assert.IsNull (expr.Method);
-#if !NET_4_0
-			Assert.AreEqual ("(1 = 2)", expr.ToString ());
-#endif
 		}
 
 		[Test]
@@ -126,9 +120,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (true, expr.IsLifted);
 			Assert.AreEqual (true, expr.IsLiftedToNull);
 			Assert.IsNull (expr.Method);
-#if !NET_4_0
-			Assert.AreEqual ("(1 = 2)", expr.ToString ());
-#endif
 		}
 
 		[Test]
@@ -154,9 +145,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (typeof (bool), expr.Type);
 			Assert.AreEqual (mi, expr.Method);
 			Assert.AreEqual ("op_Equality", expr.Method.Name);
-#if !NET_4_0
-			Assert.AreEqual ("(value(MonoTests.System.Linq.Expressions.OpClass) = value(MonoTests.System.Linq.Expressions.OpClass))", expr.ToString ());
-#endif
 		}
 
 		[Test]

+ 0 - 14
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Lambda.cs

@@ -267,19 +267,5 @@ namespace MonoTests.System.Linq.Expressions
 
 			Assert.AreEqual (5, l (1));
 		}
-#if !NET_4_0 // dlr bug 5875
-		[Test]
-		public void LambdaReturningExpression ()
-		{
-			var l = Expression.Lambda<Func<Expression>> (Expression.Constant (42));
-			Assert.AreEqual (ExpressionType.Quote, l.Body.NodeType);
-
-			var quoter = l.Compile ();
-
-			var q = quoter ();
-
-			Assert.AreEqual (ExpressionType.Constant, q.NodeType);
-		}
-#endif
 	}
 }

+ 0 - 30
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_OrElse.cs

@@ -80,9 +80,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (ExpressionType.OrElse, expr.NodeType, "OrElse#01");
 			Assert.AreEqual (typeof (bool), expr.Type, "OrElse#02");
 			Assert.IsNull (expr.Method, "OrElse#03");
-#if !NET_4_0
-			Assert.AreEqual ("(True || False)", expr.ToString(), "OrElse#04");
-#endif
 		}
 
 		[Test]
@@ -97,10 +94,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (typeof (OpClass), expr.Type, "OrElse#06");
 			Assert.AreEqual (mi, expr.Method, "OrElse#07");
 			Assert.AreEqual ("op_BitwiseOr", expr.Method.Name, "OrElse#08");
-#if !NET_4_0
-			Assert.AreEqual ("(value(MonoTests.System.Linq.Expressions.OpClass) || value(MonoTests.System.Linq.Expressions.OpClass))",
-				expr.ToString(), "OrElse#09");
-#endif
 		}
 
 		public class BrokenMethod {
@@ -283,29 +276,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.AreEqual (new Slot (64), orelse (new Slot (64), new Slot (64)));
 			Assert.AreEqual (new Slot (32), orelse (new Slot (32), new Slot (64)));
 		}
-#if !NET_4_0 // dlr bug 5867
-		[Test]
-		public void UserDefinedOrElseLiftedToNull ()
-		{
-			var l = Expression.Parameter (typeof (Slot?), "l");
-			var r = Expression.Parameter (typeof (Slot?), "r");
-
-			var method = typeof (Slot).GetMethod ("op_BitwiseOr");
-
-			var node = Expression.OrElse (l, r, method);
-			Assert.IsTrue (node.IsLifted);
-			Assert.IsTrue (node.IsLiftedToNull);
-			Assert.AreEqual (method, node.Method);
-
-			var orelse = Expression.Lambda<Func<Slot?, Slot?, Slot?>> (node, l, r).Compile ();
-
-			Assert.AreEqual (new Slot (64), orelse (new Slot (64), new Slot (64)));
-			Assert.AreEqual (new Slot (32), orelse (new Slot (32), new Slot (64)));
-			Assert.AreEqual (new Slot (64), orelse (null, new Slot (64)));
-			Assert.AreEqual (new Slot (32), orelse (new Slot (32), null));
-			Assert.AreEqual (null, orelse (null, null));
-		}
-#endif
 		[Test]
 		[Category ("NotWorkingInterpreter")]
 		public void UserDefinedOrElseShortCircuit ()

+ 0 - 11
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_Quote.cs

@@ -37,23 +37,12 @@ namespace MonoTests.System.Linq.Expressions
 			Expression.Quote (null);
 		}
 
-#if !NET_4_0
-		[Test]
-		public void QuoteConstant ()
-		{
-			UnaryExpression expr = Expression.Quote (Expression.Constant (1));
-			Assert.AreEqual (ExpressionType.Quote, expr.NodeType, "Quote#01");
-			Assert.AreEqual (typeof (ConstantExpression), expr.Type, "Quote#02");
-			Assert.AreEqual ("1", expr.ToString(), "Quote#03");
-		}
-#else
 		[Test]
 		[ExpectedException (typeof (ArgumentException))]
 		public void QuoteConstant ()
 		{
 			Expression.Quote (Expression.Constant (1));
 		}
-#endif
 
 		[Test]
 		public void CompiledQuote ()

+ 0 - 9
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_SubtractChecked.cs

@@ -184,15 +184,6 @@ namespace MonoTests.System.Linq.Expressions
 			MustOverflow<uint>  (0, 1);
 		}
 
-#if !NET_4_0 // fixed in net_4_0
-		[Test]
-		public void TestBugCompatibility ()
-		{
-			// This one does not overflow on .NET (!!!)
-			// Sounds very odd, should file a bug with MS.
-			MustNotOverflow<short> (Int16.MinValue, 1);
-		}
-#endif
 
 		//
 		// These should not overflow

+ 0 - 9
mcs/class/System.Core/Test/System.Linq.Expressions/ExpressionTest_TypeIs.cs

@@ -104,15 +104,6 @@ namespace MonoTests.System.Linq.Expressions
 			Assert.IsTrue (baz_is_bar (new Baz ()));
 		}
 
-#if !NET_4_0 // dlr bug 5868
-		[Test]
-		[Category ("NotDotNet")]
-		[ExpectedException (typeof (ArgumentException))]
-		public void TypeIsVoid ()
-		{
-			Expression.TypeIs ("yoyo".ToConstant (), typeof (void));
-		}
-#endif
 
 		public static void TacTac ()
 		{

+ 0 - 2
mcs/class/System.Core/Test/System.Linq/EnumerableFixture.cs

@@ -2124,7 +2124,6 @@ namespace MonoTests.System.Linq
 			Assert.That (Enumerable.AsEnumerable<object> (null), Is.Null);
 		}
 		
-#if NET_4_0
 		[Test]
 		[ExpectedException (typeof (ArgumentNullException))]
 		public void Zip_FirstSourceNull_ThrowsArgumentNullException ()
@@ -2157,7 +2156,6 @@ namespace MonoTests.System.Linq
 			b = new [] { 100, 200, 300 };
 			a.Zip (b, (f, s) => f + s.ToString ()).AssertEquals ("a100");
 		}
-#endif
 
 
 		private Reader<T> Read<T> (params T [] source)

+ 0 - 2
mcs/class/System.Core/Test/System.Linq/ParallelEnumerableTests.cs

@@ -24,7 +24,6 @@
 //
 //
 
-#if NET_4_0
 
 using System;
 using System.Threading;
@@ -920,4 +919,3 @@ namespace MonoTests.System.Linq
 	}
 }
 
-#endif

+ 0 - 2
mcs/class/System.Core/Test/System.Linq/ParallelTestHelper.cs

@@ -1,4 +1,3 @@
-#if NET_4_0
 // TestHelper.cs
 //
 // Copyright (c) 2008 Jérémie "Garuma" Laval
@@ -91,4 +90,3 @@ namespace MonoTests.System.Linq
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Core/Test/System.Runtime.CompilerServices/DynamicAttributeTest.cs

@@ -26,7 +26,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_4_0
 
 using System;
 using System.Runtime.CompilerServices;
@@ -62,4 +61,3 @@ namespace MonoTests.System.Runtime.CompilerServices
 	}
 }
 
-#endif

+ 0 - 2
mcs/class/System.Core/Test/System.Threading.Tasks/TaskExtensionsTests.cs

@@ -24,7 +24,6 @@
 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 // THE SOFTWARE.
 
-#if NET_4_0
 
 using System;
 using System.Threading;
@@ -56,4 +55,3 @@ namespace MonoTests.System.Threading.Tasks
 		}
 	}
 }
-#endif

+ 0 - 4
mcs/class/System.Core/Test/System.Threading/ReaderWriterLockSlimTest.cs

@@ -30,9 +30,7 @@ using System;
 using NUnit.Framework;
 using System.Threading;
 using System.Linq;
-#if NET_4_0
 using System.Threading.Tasks;
-#endif
 
 namespace MonoTests.System.Threading
 {
@@ -451,7 +449,6 @@ namespace MonoTests.System.Threading
 			Assert.IsTrue (v.TryEnterWriteLock (100));
 			v.ExitWriteLock ();
 		}
-#if NET_4_0
 		[Test]
 		public void EnterWriteLockWhileInUpgradeAndOtherWaiting ()
 		{
@@ -475,7 +472,6 @@ namespace MonoTests.System.Threading
 
             Assert.IsTrue (task1.Wait (500));
 		}
-#endif
 		[Test]
 		public void RecursiveReadLockTest ()
 		{

+ 0 - 2
mcs/class/System.Data.Services/Test/System.Data.Services.Providers/DataServiceProviderMethodsTest.cs

@@ -24,7 +24,6 @@
 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 // THE SOFTWARE.
 
-#if NET_4_0
 using System;
 using System.Collections.Generic;
 using System.Data.Services.Providers;
@@ -164,4 +163,3 @@ namespace MonoTests.System.Data.Services.Providers
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Data.Services/Test/System.Data.Services.Providers/ResourceTypeTest.cs

@@ -24,7 +24,6 @@
 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 // THE SOFTWARE.
 
-#if NET_4_0
 using System;
 using System.Collections.Generic;
 using System.Data.Services.Providers;
@@ -132,4 +131,3 @@ namespace MonoTests.System.Data.Services.Providers
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Data/Test/System.Data/DataTableTest.cs

@@ -1307,7 +1307,6 @@ namespace MonoTests.System.Data
 			}
 		}
 		
-#if NET_4_0
 		[Test]
 		public void ImportRowTypeChangeTest ()
 		{
@@ -1381,7 +1380,6 @@ namespace MonoTests.System.Data
 				}
 			}
 		}
-#endif
 			
 		[Test]
 		public void ClearReset () //To test Clear and Reset methods

+ 0 - 2
mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/DataContractResolverTest.cs

@@ -28,7 +28,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_4_0
 
 using System;
 using System.Collections;
@@ -115,4 +114,3 @@ public class ResolvedClass
 	public Guid Baz = Guid.Parse ("c74376f0-5517-4cb7-8a07-35026423f565");
 }
 
-#endif

+ 0 - 2
mcs/class/System.Runtime.Serialization/Test/System.Runtime.Serialization/XsdDataContractImporterTest2.cs

@@ -97,7 +97,6 @@ namespace MonoTests.System.Runtime.Serialization
 			Assert.That (ret.TypeArguments [0].BaseType, Is.EqualTo ("System.Int32"), "#6");
 		}
 
-#if NET_4_0		
 		[Test]
 		public void TestSimpleList3 ()
 		{
@@ -118,7 +117,6 @@ namespace MonoTests.System.Runtime.Serialization
 			Assert.That (ret.TypeArguments.Count, Is.EqualTo (1), "#5");
 			Assert.That (ret.TypeArguments [0].BaseType, Is.EqualTo ("System.Int32"), "#6");
 		}
-#endif
 		
 		[Test]
 		public void TestListOfFoo ()

+ 1 - 1
mcs/class/System.ServiceModel.Web/System.ServiceModel.Web/WebOperationContext.cs

@@ -111,7 +111,7 @@ namespace System.ServiceModel.Web
 			// do nothing
 		}
 
-#if NET_4_0 && !MOBILE
+#if !MOBILE
 		static readonly XmlWriterSettings settings = new XmlWriterSettings () { OmitXmlDeclaration = true, Indent = false };
 		XmlSerializer document_serializer, feed_serializer, item_serializer;
 

+ 0 - 2
mcs/class/System.ServiceModel.Web/Test/System.ServiceModel.Description/WebHttpBehaviorTest.cs

@@ -59,11 +59,9 @@ namespace MonoTests.System.ServiceModel.Description
 			Assert.AreEqual (WebMessageBodyStyle.Bare, b.DefaultBodyStyle, "#1");
 			Assert.AreEqual (WebMessageFormat.Xml, b.DefaultOutgoingRequestFormat, "#2");
 			Assert.AreEqual (WebMessageFormat.Xml, b.DefaultOutgoingResponseFormat, "#3");
-#if NET_4_0
 			Assert.IsFalse (b.AutomaticFormatSelectionEnabled, "#11");
 			Assert.IsFalse (b.FaultExceptionEnabled, "#12");
 			Assert.IsFalse (b.HelpEnabled, "#13");
-#endif
 		}
 
 		[Test]

+ 1 - 1
mcs/class/System.ServiceModel.Web/Test/System.ServiceModel.Description/WebHttpEndpointTest.cs

@@ -1,4 +1,4 @@
-#if NET_4_0 && !MOBILE
+#if !MOBILE
 using System;
 using System.IO;
 using System.Runtime.Serialization;

+ 2 - 2
mcs/class/System.ServiceModel.Web/Test/System.ServiceModel.Web/WebOperationContextTest.cs

@@ -72,7 +72,7 @@ namespace MonoTests.System.ServiceModel.Web
 			ch.Close ();
 		}
 
-#if NET_4_0 && !MOBILE
+#if !MOBILE
 		[Test]
 		public void CreateAtom10Response ()
 		{
@@ -138,7 +138,7 @@ namespace MonoTests.System.ServiceModel.Web
 		string TestJson3 (string s1, string s2);
 	}
 
-#if NET_4_0 && !MOBILE
+#if !MOBILE
 	public class HogeService : IHogeService
 	{
 		static XmlWriterSettings settings = new XmlWriterSettings () { OmitXmlDeclaration = true };

+ 1 - 1
mcs/class/System.ServiceModel/Assembly/AssemblyInfo.cs

@@ -75,7 +75,7 @@ using System.Runtime.InteropServices;
 [assembly: InternalsVisibleTo ("System.ServiceModel.Discovery, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")] // AnnouncementChannelEndpointElementCollection requires it.
 #endif
 
-#if NET_4_0 && HAS_ACTIVATION
+#if HAS_ACTIVATION
 
 [assembly: TypeForwardedTo (typeof (System.ServiceModel.ServiceHostingEnvironment))]
 [assembly: TypeForwardedTo (typeof (System.ServiceModel.Activation.ServiceHostFactory))]

+ 0 - 5
mcs/class/System.ServiceModel/Test/System.ServiceModel.Channels/HttpTransportBindingElementTest.cs

@@ -39,10 +39,7 @@ using System.Xml;
 using NUnit.Framework;
 
 using MonoTests.Helpers;
-
-#if NET_4_0
 using System.Security.Authentication.ExtendedProtection;
-#endif
 
 namespace MonoTests.System.ServiceModel.Channels
 {
@@ -471,10 +468,8 @@ namespace MonoTests.System.ServiceModel.Channels
 			http_binding_element.TransferMode = TransferMode.Streamed;
 			http_binding_element.UnsafeConnectionNtlmAuthentication = !http_binding_element.UnsafeConnectionNtlmAuthentication;
 			http_binding_element.UseDefaultWebProxy = !http_binding_element.UseDefaultWebProxy;
-#if NET_4_0
 			http_binding_element.DecompressionEnabled = !http_binding_element.DecompressionEnabled;
 			http_binding_element.ExtendedProtectionPolicy = new ExtendedProtectionPolicy (PolicyEnforcement.WhenSupported);
-#endif
 
 			// 
 			// Actual call to ExportPolicy

+ 0 - 2
mcs/class/System.ServiceModel/Test/System.ServiceModel.Channels/MsmqBindingElementBaseTest.cs

@@ -107,11 +107,9 @@ namespace MonoTests.System.ServiceModel.Channels
 			binding_element.TimeToLive = TimeSpan.FromSeconds (60);
 			binding_element.UseMsmqTracing = !binding_element.UseMsmqTracing;
 			binding_element.UseSourceJournal = !binding_element.UseSourceJournal;
-#if NET_4_0
 			// This ones haven't been implemented yet, so comment them for now.
 			//binding_element.ReceiveContextEnabled = !binding_element.ReceiveContextEnabled;
 			//binding_element.ValidityDuration = TimeSpan.FromSeconds (30);
-#endif
 
 			binding_element.MsmqTransportSecurity.MsmqAuthenticationMode = MsmqAuthenticationMode.Certificate;
 			binding_element.MsmqTransportSecurity.MsmqEncryptionAlgorithm = MsmqEncryptionAlgorithm.Aes;

+ 0 - 2
mcs/class/System.ServiceModel/Test/System.ServiceModel.Configuration/StandardEndpointsSectionTest.cs

@@ -25,7 +25,6 @@
 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
-#if NET_4_0
 
 using System;
 using System.Collections.Generic;
@@ -52,4 +51,3 @@ namespace MonoTests.System.ServiceModel.Configuration
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.ServiceModel/Test/System.ServiceModel.Description/ServiceMetadataEndpointTest.cs

@@ -25,7 +25,6 @@
 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
-#if NET_4_0
 
 using System;
 using System.Collections.Generic;
@@ -54,4 +53,3 @@ namespace MonoTests.System.ServiceModel.Description
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.ServiceModel/Test/System.ServiceModel.Dispatcher/Bug652331_2Test.cs

@@ -1,4 +1,3 @@
-#if NET_4_0
 //
 // Authors:
 //	David Straw
@@ -857,4 +856,3 @@ namespace WebServiceMoonlightTest.ServiceReference2 {
     }
 }
 
-#endif

+ 0 - 2
mcs/class/System.ServiceModel/Test/System.ServiceModel/ChannelFactory_1Test.cs

@@ -434,14 +434,12 @@ namespace MonoTests.System.ServiceModel
 			Assert.AreEqual ("callResult", res.val, "#2");
 		}
 
-#if NET_4_0
 		[Test]
 		public void ConstructorServiceEndpoint ()
 		{
 			// It is okay to pass ServiceEndpoint that does not have Binding or EndpointAddress.
 			new ChannelFactory<IRequestChannel> (new ServiceEndpoint (ContractDescription.GetContract (typeof (IMetadataExchange)), null, null));
 		}
-#endif
 
 		public T CreateFooComplexMC_Channel<T> (bool isXml)
 		{

+ 0 - 2
mcs/class/System.ServiceModel/Test/System.ServiceModel/ClientBaseTest.cs

@@ -479,7 +479,6 @@ namespace MonoTests.System.ServiceModel
 			}
 		}
 
-#if NET_4_0
 		[Test]
 		public void ConstructorServiceEndpoint ()
 		{
@@ -504,6 +503,5 @@ namespace MonoTests.System.ServiceModel
 			{
 			}
 		}
-#endif
 	}
 }

+ 0 - 2
mcs/class/System.ServiceModel/Test/System.ServiceModel/ServiceHostBaseTest.cs

@@ -373,7 +373,6 @@ namespace MonoTests.System.ServiceModel
 			return host;
 		}
 
-#if NET_4_0
 		[Test]
 		public void AddServiceEndpoint_Directly ()
 		{
@@ -422,7 +421,6 @@ namespace MonoTests.System.ServiceModel
 			var contract = ContractDescription.GetContract (typeof (INotImplementedService));
 			host.AddServiceEndpoint (new ServiceEndpoint (contract, binding, address));
 		}
-#endif
 
 		#region helpers
 

File diff suppressed because it is too large
+ 0 - 31
mcs/class/System.Web.Extensions/Test/System.Web.UI.WebControls/ListViewTest.cs


+ 0 - 4
mcs/class/System.Web.Routing/Test/System.Web.Routing/FakeHttpWorkerRequest.cs

@@ -81,11 +81,7 @@ namespace MonoTests.Common
 
         public override string GetRawUrl ()
         {
-#if NET_4_0
 	    return "/GetRawUrl";
-#else
-            return "GetRawUrl";
-#endif
         }
 
         public override string GetHttpVerbName ()

+ 0 - 6
mcs/class/System.Web.Routing/Test/System.Web.Routing/RequestContext.cs

@@ -40,7 +40,6 @@ namespace MonoTests.System.Web.Routing
 	[TestFixture]
 	public class RequestContextTest
 	{
-#if NET_4_0
 		[Test]
 		public void DefaultConstructor ()
 		{
@@ -49,7 +48,6 @@ namespace MonoTests.System.Web.Routing
 			Assert.AreEqual (null, rc.HttpContext, "#A1");
 			Assert.AreEqual (null, rc.RouteData, "#A2");
 		}
-#endif
 		[Test]
 		public void Constructor_HttpContextBase_RouteData ()
 		{
@@ -72,14 +70,12 @@ namespace MonoTests.System.Web.Routing
 			var rc = new RequestContext (ctx, new RouteData ());
 
 			Assert.AreSame (ctx, rc.HttpContext, "#A1");
-#if NET_4_0
 			ctx = new HttpContextWrapper (new HttpContext (new HttpRequest ("filename", "http://localhost/filename", String.Empty), new HttpResponse (new StringWriter ())));
 			rc.HttpContext = ctx;
 			Assert.AreSame (ctx, rc.HttpContext, "#A2");
 
 			rc.HttpContext = null;
 			Assert.IsNull (rc.HttpContext, "#A3");
-#endif
 		}
 
 		[Test]
@@ -90,14 +86,12 @@ namespace MonoTests.System.Web.Routing
 			var rc = new RequestContext (ctx, rd);
 
 			Assert.AreSame (rd, rc.RouteData, "#A1");
-#if NET_4_0
 			rd = new RouteData ();
 			rc.RouteData = rd;
 			Assert.AreSame (rd, rc.RouteData, "#A2");
 
 			rc.RouteData = null;
 			Assert.IsNull (rc.RouteData, "#A3");
-#endif
 		}
 	}
 }

+ 0 - 11
mcs/class/System.Web.Routing/Test/System.Web.Routing/RouteCollectionTest.cs

@@ -131,17 +131,8 @@ namespace MonoTests.System.Web.Routing
 		{
 			var rd = new RouteCollection () { RouteExistingFiles = true }.GetRouteData (new HttpContextStub2 (null, null, null));
 			Assert.IsNull (rd, "#A1");
-#if NET_4_0
 			rd = new RouteCollection ().GetRouteData (new HttpContextStub2 (null, null, null));
 			Assert.IsNull (rd, "#A2");
-#else
-			try {
-				new RouteCollection ().GetRouteData (new HttpContextStub2 (null, null, null));
-				Assert.Fail ("#A3");
-			} catch (NotImplementedException) {
-				// it should fail due to the NIE on AppRelativeCurrentExecutionFilePath.
-			}
-#endif
 		}
 
 		[Test]
@@ -648,7 +639,6 @@ namespace MonoTests.System.Web.Routing
 			
 			Assert.IsNotNull (rd, "#A1");
 		}
-#if NET_4_0
 		[Test]
 		public void Ignore_String ()
 		{
@@ -926,6 +916,5 @@ namespace MonoTests.System.Web.Routing
 			Assert.AreEqual (typeof (PageRouteHandler), rd.RouteHandler.GetType (), "#A4-3");
 			Assert.IsFalse (((PageRouteHandler) rd.RouteHandler).CheckPhysicalUrlAccess, "#A4-4");
 		}
-#endif
 	}
 }

+ 0 - 18
mcs/class/System.Web.Routing/Test/System.Web.Routing/RouteTest.cs

@@ -627,7 +627,6 @@ namespace MonoTests.System.Web.Routing
 			var hc = new HttpContextStub ("~/xyzxyzxyzxyzblah", String.Empty);
 			var rd = r.GetRouteData (hc);
 
-#if NET_4_0 || !DOTNET
 			// When running on Mono this test succeeds - it was a bug in .NET routing for 3.5 which
 			// we don't reproduce anymore.
 			Assert.IsNotNull (rd, "#1");
@@ -637,9 +636,6 @@ namespace MonoTests.System.Web.Routing
 			Assert.AreEqual ("xyz", rd.Values ["foo"], "#4-1");
 			Assert.AreEqual ("xyz", rd.Values ["bar"], "#4-2");
 			Assert.AreEqual ("blah", rd.Values ["baz"], "#4-3");
-#else
-			Assert.IsNull (rd, "#1");
-#endif
 		}
 
 		[Test]
@@ -738,7 +734,6 @@ namespace MonoTests.System.Web.Routing
 			var hc = new HttpContextStub ("~/xyzxyzxyzxyzxyzxyzblah", String.Empty);
 			var rd = r.GetRouteData (hc);
 
-#if NET_4_0 || !DOTNET
 			// When running on Mono this test succeeds - it was a bug in .NET routing for 3.5 which
 			// we don't reproduce anymore.
 			Assert.IsNotNull (rd, "#1");
@@ -748,9 +743,6 @@ namespace MonoTests.System.Web.Routing
 			Assert.AreEqual ("xyzxyzxyz", rd.Values ["foo"], "#4-1");
 			Assert.AreEqual ("xyz", rd.Values ["bar"], "#4-2");
 			Assert.AreEqual ("blah", rd.Values ["baz"], "#4-3");
-#else
-			Assert.IsNull (rd, "#1");
-#endif
 		}
 
 		[Test]
@@ -776,7 +768,6 @@ namespace MonoTests.System.Web.Routing
 			var hc = new HttpContextStub ("~/xyzxyzxyzdabxyzblah", String.Empty);
 			var rd = r.GetRouteData (hc);
 
-#if NET_4_0 || !DOTNET
 			// When running on Mono this test succeeds - it was a bug in .NET routing for 3.5 which
 			// we don't reproduce anymore.
 			Assert.IsNotNull (rd, "#1");
@@ -786,9 +777,6 @@ namespace MonoTests.System.Web.Routing
 			Assert.AreEqual ("xyz", rd.Values ["foo"], "#4-1");
 			Assert.AreEqual ("dab", rd.Values ["bar"], "#4-2");
 			Assert.AreEqual ("blah", rd.Values ["baz"], "#4-3");
-#else
-			Assert.IsNull (rd, "#1");
-#endif
 		}
 
 		[Test]
@@ -798,7 +786,6 @@ namespace MonoTests.System.Web.Routing
 			var hc = new HttpContextStub ("~/xyzxyzxyzxyzxyz", String.Empty);
 			var rd = r.GetRouteData (hc);
 
-#if NET_4_0 || !DOTNET
 			// When running on Mono this test succeeds - it was a bug in .NET routing for 3.5 which
 			// we don't reproduce anymore.
 			Assert.IsNotNull (rd, "#1");
@@ -808,9 +795,6 @@ namespace MonoTests.System.Web.Routing
 			Assert.AreEqual ("xyz", rd.Values ["foo"], "#4-1");
 			Assert.AreEqual ("xyz", rd.Values ["bar"], "#4-2");
 			Assert.AreEqual ("xyz", rd.Values ["baz"], "#4-3");
-#else
-			Assert.IsNull (rd, "#1");
-#endif
 		}
 
 		[Test]
@@ -1375,7 +1359,6 @@ namespace MonoTests.System.Web.Routing
 
 		}
 		
-#if NET_4_0
 		[Test (Description="Bug #671753")]
 		public void GetVirtualPath15 ()
 		{
@@ -1396,7 +1379,6 @@ namespace MonoTests.System.Web.Routing
 			Assert.IsNotNull (RouteTable.Routes.GetVirtualPath (rc, "TestRoute", new RouteValueDictionary ()), "#A3");
 			Assert.IsNotNull (RouteTable.Routes.GetVirtualPath (rc, "TestRoute", null), "#A4");
 		}
-#endif
 
 		[Test (Description="Xamarin Bug #9116")]
 		public void GetVirtualPath16 ()

+ 0 - 2
mcs/class/System.Web.Routing/Test/System.Web.Routing/TestStubTypes.cs

@@ -248,7 +248,6 @@ namespace MonoTests.System.Web.Routing
 
 		public string RewrittenPath { get; set; }
 	}
-#if NET_4_0
 	class FakeHttpRequestWrapper : HttpRequestWrapper
 	{
 		string requestUrl;
@@ -320,7 +319,6 @@ namespace MonoTests.System.Web.Routing
 			wrapper = new FakeHttpRequestWrapper (requestUrl, path, appPath);
 		}
 	}
-#endif
 	public class MyStopRoutingHandler : StopRoutingHandler
 	{
 		public IHttpHandler CallGetHttpHandler (RequestContext rc)

+ 0 - 75
mcs/class/System.Web.Routing/Test/System.Web.Routing/UrlRoutingModuleTest.cs

@@ -85,17 +85,6 @@ namespace MonoTests.System.Web.Routing
 			m.PostResolveRequestCache (new HttpContextStub2 ("~/foo/bar", null));
 		}
 
-#if !NET_4_0
-		[Test]
-		[ExpectedException (typeof (InvalidOperationException))]
-		public void PostResolveRequestCacheNullHttpHandler ()
-		{
-			var m = new UrlRoutingModule ();
-			RouteTable.Routes.Add (new MyRoute ("foo/bar", new NullRouteHandler ()));
-
-			m.PostResolveRequestCache (new HttpContextStub2 ("~/foo/bar", null));
-		}
-#endif
 		[Test]
 		[ExpectedException (typeof (NotImplementedException))]
 		public void PostResolveRequestCacheNoPath ()
@@ -106,53 +95,15 @@ namespace MonoTests.System.Web.Routing
 			m.PostResolveRequestCache (new HttpContextStub2 ("~/foo/bar", null));
 		}
 
-#if !NET_4_0
-		[Test]
-		public void PostResolveRequestCacheCallRewritePath ()
-		{
-			var m = new UrlRoutingModule ();
-			RouteTable.Routes.Add (new MyRoute ("{foo}/{bar}", new MyRouteHandler ()));
-			var hc = new HttpContextStub2 ("~/x/y", "z");
-			try {
-				m.PostResolveRequestCache (hc);
-				Assert.Fail ("#1");
-			} catch (ApplicationException ex) {
-				Assert.AreEqual ("~/UrlRouting.axd", ex.Message, "#2");
-			}
-		}
-
-		[Test]
-		public void PostResolveRequestCacheModifiedPath ()
-		{
-			var m = new UrlRoutingModule ();
-			RouteTable.Routes.Add (new MyRoute ("{foo}/{bar}", new MyRouteHandler ()));
-			var hc = new HttpContextStub2 ("~/x/y", "z", "apppath");
-			hc.SetResponse (new HttpResponseStub (2));
-			try {
-				m.PostResolveRequestCache (hc);
-				Assert.Fail ("#1");
-			} catch (ApplicationException ex) {
-				Assert.AreEqual ("~/UrlRouting.axd", ex.Message, "#2");
-			}
-		}
-#endif
 		[Test]
 		public void PostResolveRequestCache ()
 		{
 			var m = new UrlRoutingModule ();
 			RouteTable.Routes.Add (new MyRoute ("{foo}/{bar}", new MyRouteHandler ()));
-#if NET_4_0
 			var hc = new HttpContextStub4 ("~/x/y", "z", "apppath", false);
-#else
-			var hc = new HttpContextStub3 ("~/x/y", "z", "apppath", false);
-#endif
 			hc.SetResponse (new HttpResponseStub (2));
 			m.PostResolveRequestCache (hc);
-#if NET_4_0
 			Assert.AreEqual (null, hc.RewrittenPath, "#1");
-#else
-			Assert.AreEqual ("~/UrlRouting.axd", hc.RewrittenPath, "#1");
-#endif
 			// it internally stores the handler 
 		}
 		
@@ -203,49 +154,23 @@ namespace MonoTests.System.Web.Routing
 		{
 			var m = new UrlRoutingModule ();
 			RouteTable.Routes.Add (new MyRoute ("{foo}/{bar}", new MyRouteHandler ()));
-#if NET_4_0
 			var hc = new HttpContextStub4 ("~/x/y", "z", "apppath", true);
-#else
-			var hc = new HttpContextStub3 ("~/x/y", "z", "apppath", true);
-#endif
 			hc.HttpHandler = new MyHttpHandler ();
 			hc.SetResponse (new HttpResponseStub (2));
 			m.PostResolveRequestCache (hc);
-#if NET_4_0
 			Assert.AreEqual (null, hc.RewrittenPath, "#1");
-#else
-			Assert.AreEqual ("~/UrlRouting.axd", hc.RewrittenPath, "#1");
-#endif
 			// It tries to set Handler and causes NIE
 			m.PostMapRequestHandler (hc);
 		}
 
 		[Test]
-#if !NET_4_0
-		[ExpectedException (typeof (ApplicationException))]
-#endif
 		public void Pipeline3 ()
 		{
 			var m = new UrlRoutingModule ();
 			RouteTable.Routes.Add (new MyRoute ("{foo}/{bar}", new MyRouteHandler ()));
-#if NET_4_0
 			var hc = new HttpContextStub5 ("~/x/y", String.Empty, "apppath");
-#else
-			var hc = new HttpContextStub2 ("~/x/y", String.Empty, "apppath");
-#endif
 			hc.SetResponse (new HttpResponseStub (2));
-#if NET_4_0
 			Assert.IsNull (m.RouteCollection.GetRouteData (hc), "#0");
-#else
-			Assert.IsNotNull (m.RouteCollection.GetRouteData (hc), "#0");
-			m.PostResolveRequestCache (hc);
-			try {
-				m.PostMapRequestHandler (hc);
-				Assert.Fail ("#1");
-			} catch (ApplicationException ex) {
-				Assert.AreEqual ("~/UrlRouting.axd", ex.Message, "#2");
-			}
-#endif
 		}
 	}
 }

+ 0 - 5
mcs/class/System.Web/System.Web.UI.WebControls/Table.cs

@@ -248,11 +248,6 @@ namespace System.Web.UI.WebControls {
 				writer.Write (s);
 				writer.RenderEndTag ();
 			}
-// #if !NET_4_0
-// 			else if (HasControls ()) {
-// 				writer.Indent++;
-// 			}
-// #endif
 		}
 
 		void IPostBackEventHandler.RaisePostBackEvent (string argument)

+ 1 - 1
mcs/class/System.Web/System.Web.Util/HttpEncoder.cs

@@ -35,7 +35,7 @@ using System.Collections.Generic;
 using System.Configuration;
 using System.IO;
 using System.Text;
-#if !NO_SYSTEM_WEB_DEPENDENCY && NET_4_0 && !MOBILE
+#if !NO_SYSTEM_WEB_DEPENDENCY && !MOBILE
 using System.Web.Configuration;
 #endif
 

+ 0 - 1
mcs/class/System.Web/System.Web_test.dll.sources

@@ -272,7 +272,6 @@ System.Web.UI.WebControls/RangeValidatorTest.cs
 System.Web.UI.WebControls/RectangleHotSpotTest.cs
 System.Web.UI.WebControls/RegularExpressionValidatorTest.cs
 System.Web.UI.WebControls/RepeatInfoTest.auto.cs
-System.Web.UI.WebControls/RepeatInfoTest.auto.2.0.cs
 System.Web.UI.WebControls/RepeatInfoTest.auto.4.0.cs
 System.Web.UI.WebControls/RepeatInfoTest.cs
 System.Web.UI.WebControls/RepeatInfoUser.cs

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Caching/FileResponseElementTest.cs

@@ -28,7 +28,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_4_0
 using System;
 using System.Web;
 using System.Web.Caching;
@@ -70,4 +69,3 @@ namespace MonoTests.System.Web.Caching
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Caching/HeaderElementTest.cs

@@ -28,7 +28,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_4_0
 using System;
 using System.Web;
 using System.Web.Caching;
@@ -68,4 +67,3 @@ namespace MonoTests.System.Web.Caching
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Caching/MemoryResponseElementTest.cs

@@ -28,7 +28,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_4_0
 using System;
 using System.Web;
 using System.Web.Caching;
@@ -74,4 +73,3 @@ namespace MonoTests.System.Web.Caching
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Caching/SqlCacheDependencyTest.cs

@@ -65,7 +65,6 @@ namespace MonoTests.System.Web.Caching
 			//}, "#A3");
 		}
 
-#if NET_4_0
 		[Test]
 		public void CreateOutputCacheDependency ()
 		{
@@ -90,7 +89,6 @@ namespace MonoTests.System.Web.Caching
 			//sqc = SqlCacheDependency.CreateOutputCacheDependency ("Database:table; AnotherDatabase:table");
 			//Assert.IsTrue (sql is AggregateCacheDependency, "#B2");
 		}
-#endif
 	}
 }
 

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Caching/SubstitutionResponseElementTest.cs

@@ -28,7 +28,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_4_0
 using System;
 using System.Web;
 using System.Web.Caching;
@@ -61,4 +60,3 @@ namespace MonoTests.System.Web.Caching
 		}
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Compilation/BuildManagerTest.cs

@@ -41,7 +41,6 @@ namespace MonoTests.System.Web.Compilation
 	[Serializable]
 	public class BuildManagerTest
 	{
-#if NET_4_0
 		[Test]
 		[Ignore ("Pending investigation if it is indeed the correct test.")]
 		public void GetGlobalAsaxType ()
@@ -59,6 +58,5 @@ namespace MonoTests.System.Web.Compilation
 			Assert.AreEqual ("", BuildManager.TargetFramework.Profile, "#A1-3");
 			Assert.AreEqual (new Version (4, 0), BuildManager.TargetFramework.Version, "#A1-4");
 		}
-#endif
 	}
 }

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Compilation/BuildProviderTest.cs

@@ -25,7 +25,6 @@
 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
-#if NET_4_0
 using System;
 using System.CodeDom;
 using System.IO;
@@ -78,4 +77,3 @@ namespace MonoTests.System.Web.Compilation
 	{
 	}
 }
-#endif

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Compilation/RouteUrlExpressionBuilderTest.cs

@@ -25,7 +25,6 @@
 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
-#if NET_4_0
 using System;
 using System.CodeDom;
 using System.IO;
@@ -286,4 +285,3 @@ namespace MonoTests.System.Web.Compilation
 		}
 	}
 }
-#endif

+ 0 - 12
mcs/class/System.Web/Test/System.Web.Configuration/MachineKeySectionTest.cs

@@ -40,26 +40,16 @@ namespace MonoTests.System.Web.Configuration {
 		public void DefaultValues ()
 		{
 			MachineKeySection section = new MachineKeySection ();
-#if NET_4_0
 			Assert.AreEqual (MachineKeyCompatibilityMode.Framework20SP1, section.CompatibilityMode, "CompatibilityMode");
-#endif
 			Assert.AreEqual ("Auto", section.Decryption, "Decryption");
 			Assert.AreEqual ("AutoGenerate,IsolateApps", section.DecryptionKey, "DecryptionKey");
-#if NET_4_0
 			Assert.AreEqual (MachineKeyValidation.HMACSHA256, section.Validation, "Validation");
 			Assert.AreEqual ("HMACSHA256", section.ValidationAlgorithm, "ValidationAlgorithm");
-#else
-			Assert.AreEqual (MachineKeyValidation.SHA1, section.Validation, "Validation");
-#endif
 			Assert.AreEqual ("AutoGenerate,IsolateApps", section.ValidationKey, "ValidationKey");
 		}
 
 		[Test]
-#if NET_4_0
 		[ExpectedException (typeof (NullReferenceException))]
-#else
-		[ExpectedException (typeof (ConfigurationErrorsException))]
-#endif
 		public void Decryption_Null ()
 		{
 			MachineKeySection section = new MachineKeySection ();
@@ -73,7 +63,6 @@ namespace MonoTests.System.Web.Configuration {
 			MachineKeySection section = new MachineKeySection ();
 			section.Decryption = String.Empty;
 		}
-#if NET_4_0
 		[Test]
 		public void Decryption_RC2 ()
 		{
@@ -172,7 +161,6 @@ namespace MonoTests.System.Web.Configuration {
 			Assert.AreEqual (MachineKeyValidation.Custom, section.Validation, "after");
 			Assert.AreEqual ("alg:UnexistingType", section.ValidationAlgorithm, "ValidationAlgorithm");
 		}
-#endif
 	}
 }
 

+ 0 - 20
mcs/class/System.Web/Test/System.Web.Configuration/MachineKeyValidationConverterTest.cs

@@ -77,7 +77,6 @@ namespace MonoTests.System.Web.Configuration {
 
 			o = cv.ConvertFrom (null, null, "AES");
 			Assert.AreEqual ("AES", o.ToString (), "AES");
-#if NET_4_0
 			o = cv.ConvertFrom (null, null, "HMACSHA256");
 			Assert.AreEqual ("HMACSHA256", o.ToString (), "HMACSHA256");
 
@@ -86,10 +85,8 @@ namespace MonoTests.System.Web.Configuration {
 
 			o = cv.ConvertFrom (null, null, "HMACSHA512");
 			Assert.AreEqual ("HMACSHA512", o.ToString (), "HMACSHA512");
-#endif
 		}
 
-#if NET_4_0
 		[Test]
 		[ExpectedException (typeof (ArgumentException))]
 		public void ConvertFrom_Custom ()
@@ -97,7 +94,6 @@ namespace MonoTests.System.Web.Configuration {
 			MachineKeyValidationConverter cv = new MachineKeyValidationConverter ();
 			cv.ConvertFrom (null, null, "Custom");
 		}
-#endif
 
 		[Test]
 		[ExpectedException (typeof (ArgumentException))]
@@ -126,14 +122,11 @@ namespace MonoTests.System.Web.Configuration {
 			Assert.AreEqual ("MD5", cv.ConvertTo (null, null, MachineKeyValidation.MD5, typeof (string)), "A1");
 			Assert.AreEqual ("SHA1", cv.ConvertTo (null, null, MachineKeyValidation.SHA1, typeof (string)), "A2");
 			Assert.AreEqual ("3DES", cv.ConvertTo (null, null, MachineKeyValidation.TripleDES, typeof (string)), "A3");
-#if NET_4_0
 			Assert.AreEqual ("HMACSHA256", cv.ConvertTo (null, null, MachineKeyValidation.HMACSHA256, typeof (string)), "HMACSHA256");
 			Assert.AreEqual ("HMACSHA384", cv.ConvertTo (null, null, MachineKeyValidation.HMACSHA384, typeof (string)), "HMACSHA384");
 			Assert.AreEqual ("HMACSHA512", cv.ConvertTo (null, null, MachineKeyValidation.HMACSHA512, typeof (string)), "HMACSHA512");
-#endif
 		}
 
-#if NET_4_0
 		[Test]
 		[ExpectedException (typeof (ArgumentException))]
 		public void ConvertTo_Custom ()
@@ -141,14 +134,9 @@ namespace MonoTests.System.Web.Configuration {
 			MachineKeyValidationConverter cv = new MachineKeyValidationConverter ();
 			cv.ConvertTo (null, null, MachineKeyValidation.Custom, typeof (string));
 		}
-#endif
 
 		[Test]
-#if NET_4_0
 		[ExpectedException (typeof (ArgumentException))]
-#else
-		[ExpectedException (typeof (NullReferenceException))]
-#endif
 		public void ConvertTo_NullError ()
 		{
 			MachineKeyValidationConverter cv = new MachineKeyValidationConverter ();
@@ -157,11 +145,7 @@ namespace MonoTests.System.Web.Configuration {
 		}
 
 		[Test]
-#if NET_4_0
 		[ExpectedException (typeof (ArgumentException))]
-#else
-		[ExpectedException (typeof (FormatException))]
-#endif
 		public void ConvertTo_TypeError1 ()
 		{
 			MachineKeyValidationConverter cv = new MachineKeyValidationConverter ();
@@ -179,11 +163,7 @@ namespace MonoTests.System.Web.Configuration {
 		}
 
 		[Test]
-#if NET_4_0
 		[ExpectedException (typeof (ArgumentException))]
-#else
-		[ExpectedException (typeof (FormatException))]
-#endif
 		public void ConvertTo_TypeError3 ()
 		{
 			MachineKeyValidationConverter cv = new MachineKeyValidationConverter ();

+ 0 - 2
mcs/class/System.Web/Test/System.Web.Security/MachineKeyTest.cs

@@ -28,7 +28,6 @@
 using System.Security.Cryptography;
 
 
-#if NET_4_0
 using System;
 using System.Text;
 using System.Web.Security;
@@ -204,4 +203,3 @@ namespace MonoTests.System.Web.Security
 #endif
 	}
 }
-#endif

+ 0 - 4
mcs/class/System.Web/Test/System.Web.UI.HtmlControls/HtmlFormTest.cs

@@ -200,11 +200,9 @@ namespace MonoTests.System.Web.UI.HtmlControls {
 
 			// Indirect test for HttpRequest.QueryStringRaw, see
 			// https://bugzilla.novell.com/show_bug.cgi?id=376352
-#if NET_4_0
 			Assert.AreEqual (" method=\"post\" action=\"?q=1&amp;q2=2\"", attrs, "A1");
 			form.RenderingCompatibility = new Version (3, 5);
 			attrs = form.RenderAttributes ();
-#endif
 			Assert.AreEqual (" name=\"aspnetForm\" method=\"post\" action=\"?q=1&amp;q2=2\"", attrs, "A2");
 		}
 #endif
@@ -218,11 +216,9 @@ namespace MonoTests.System.Web.UI.HtmlControls {
 			form.Page = p;
 			form.Action = "someactionfile.aspx";
 			string attrs = form.RenderAttributes ();
-#if NET_4_0
 			Assert.AreEqual (" method=\"post\" action=\"someactionfile.aspx\"", attrs, "A1");
 			form.RenderingCompatibility = new Version (3, 5);
 			attrs = form.RenderAttributes ();
-#endif
 			Assert.AreEqual (" name=\"aspnetForm\" method=\"post\" action=\"someactionfile.aspx\"", attrs, "A2");
 		}
 		

+ 0 - 5
mcs/class/System.Web/Test/System.Web.UI.HtmlControls/HtmlInputButtonTest.cs

@@ -157,13 +157,8 @@ namespace MonoTests.System.Web.UI.HtmlControls {
 		[Test]
 		public void OnClickAttributeWithSpecials ()
 		{
-#if NET_4_0
 			string origHtml = "alert(&#39;&lt;&amp;&#39;);";
 			string origHtml2 = "alert('<&');";
-#else
-			string origHtml = "alert('&lt;&amp;');";
-			string origHtml2 = "alert('<&');";
-#endif
 
 			StringWriter sw = new StringWriter ();
 			HtmlTextWriter tw = new HtmlTextWriter (sw);

+ 0 - 2
mcs/class/System.Web/Test/System.Web.UI.WebControls.Adapters/MenuAdapterTest.cs

@@ -57,9 +57,7 @@ namespace MonoTests.System.Web.UI.WebControls.Adapters
 		{
 			p = new Page ();
 			c = new MyMenu ();
-#if NET_4_0
 			c.RenderingMode = MenuRenderingMode.Table;
-#endif
 			a = new MyMenuAdapter (c);
 			p.Controls.Add(c);
 			sw = new StringWriter ();

+ 0 - 2
mcs/class/System.Web/Test/System.Web.UI.WebControls/BaseDataBoundControlTest.cs

@@ -180,7 +180,6 @@ namespace MonoTests.System.Web.UI.WebControls
 			p.DataSource = new Object();
 			Assert.AreEqual (true, p.ValidateDataSourceCalled);
 		}
-#if NET_4_0
 		[Test]
 		public void SupportsDisabledAttribute ()
 		{
@@ -194,6 +193,5 @@ namespace MonoTests.System.Web.UI.WebControls
 			Assert.AreEqual (ver35, p.RenderingCompatibility, "#A2-1");
 			Assert.IsTrue (p.SupportsDisabledAttribute, "#A2-2");
 		}
-#endif
 	}
 }

+ 0 - 2
mcs/class/System.Web/Test/System.Web.UI.WebControls/BaseDataListTest.cs

@@ -802,7 +802,6 @@ namespace MonoTests.System.Web.UI.WebControls {
 			// and junk
 			Assert.IsFalse (BaseDataList.IsBindableType (this.GetType ()), "this");
 		}
-#if NET_4_0
 		[Test]
 		public void SupportsDisabledAttribute ()
 		{
@@ -816,6 +815,5 @@ namespace MonoTests.System.Web.UI.WebControls {
 			Assert.AreEqual (ver35, p.RenderingCompatibility, "#A2-1");
 			Assert.IsTrue (p.SupportsDisabledAttribute, "#A2-2");
 		}
-#endif
 	}
 }

+ 0 - 12
mcs/class/System.Web/Test/System.Web.UI.WebControls/BoundFieldTest.cs

@@ -130,11 +130,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test (Description="Bug 646505")]
 		public void BoundField_Bug646505 ()
 		{
-#if NET_4_0
 			string originalHtml = "<div>\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\n\t\t<tr>\n\t\t\t<th scope=\"col\">&nbsp;</th><th scope=\"col\">&nbsp;</th>\n\t\t</tr><tr>\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;gridView$ctl02$ctl00&#39;,&#39;&#39;)\">Update</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;gridView&#39;,&#39;Cancel$0&#39;)\">Cancel</a></td><td><input name=\"gridView$ctl02$ctl02\" type=\"text\" value=\"False\" /></td>\n\t\t</tr><tr>\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;gridView&#39;,&#39;Edit$1&#39;)\">Edit</a></td><td>False</td>\n\t\t</tr>\n\t</table>\n</div>\n";
-#else
-			string originalHtml = "<div>\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\n\t\t<tr>\n\t\t\t<th scope=\"col\">&nbsp;</th><th scope=\"col\">&nbsp;</th>\n\t\t</tr><tr>\n\t\t\t<td><a href=\"javascript:__doPostBack('gridView$ctl02$ctl00','')\">Update</a>&nbsp;<a href=\"javascript:__doPostBack('gridView','Cancel$0')\">Cancel</a></td><td><input name=\"gridView$ctl02$ctl02\" type=\"text\" value=\"False\" /></td>\n\t\t</tr><tr>\n\t\t\t<td><a href=\"javascript:__doPostBack('gridView','Edit$1')\">Edit</a></td><td>False</td>\n\t\t</tr>\n\t</table>\n</div>\n";
-#endif
 			WebTest t = new WebTest ("BoundField_Bug646505.aspx");
 			t.Run ();
 
@@ -371,11 +367,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			Assert.IsTrue (bf.DoSupportsHtmlEncode, "#A1-3");
 
 			bf.DataFormatString = formatString;
-#if NET_4_0
 			Assert.AreEqual ("&lt;script&gt;alert (&#39;&lt;test&gt;&#39;);&lt;/script&gt;", bf.DoFormatDataValue ("<test>", true), "#A2");
-#else
-			Assert.AreEqual ("&lt;script&gt;alert ('&lt;test&gt;');&lt;/script&gt;", bf.DoFormatDataValue ("<test>", true), "#A2");
-#endif
 			Assert.AreEqual (String.Format (formatString, "<test>"), bf.DoFormatDataValue ("<test>", false), "#A3");
 
 			bf.HtmlEncodeFormatString = false;
@@ -383,11 +375,7 @@ namespace MonoTests.System.Web.UI.WebControls
 
 			var ec = new EncodingTest ();
 			bf.HtmlEncodeFormatString = true;
-#if NET_4_0
 			Assert.AreEqual ("&lt;script&gt;alert (&#39;&lt;EncodingTest&gt;&amp;&#39;);&lt;/script&gt;", bf.DoFormatDataValue (ec, true), "#A4");
-#else
-			Assert.AreEqual ("&lt;script&gt;alert ('&lt;EncodingTest&gt;&amp;');&lt;/script&gt;", bf.DoFormatDataValue (ec, true), "#A4");
-#endif
 		}
 
 		[Test]

+ 0 - 2
mcs/class/System.Web/Test/System.Web.UI.WebControls/ChangePasswordTest.cs

@@ -823,7 +823,6 @@ namespace MonoTests.System.Web.UI.WebControls
 			RequiredFieldValidator rfv = cp.ChangePasswordTemplateContainer.FindControl ("text1required") as RequiredFieldValidator;
 			Assert.IsNotNull (rfv, "#A2");
 		}
-#if NET_4_0
 		[Test]
 		public void RenderOuterTableForbiddenStyles ()
 		{
@@ -890,7 +889,6 @@ namespace MonoTests.System.Web.UI.WebControls
 				}
 			}
 		}
-#endif
 		[TestFixtureTearDown]
 		public void TearDown ()
 		{

+ 0 - 20
mcs/class/System.Web/Test/System.Web.UI.WebControls/CheckBoxFieldTest.cs

@@ -127,11 +127,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test (Description="Bug 595568 #0")]
 		public void CheckBoxField_Bug595568_0 ()
 		{
-#if NET_4_0
 			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span title=\"Dummy\"><input id=\"gridView_ctl00_0\" type=\"checkbox\" name=\"gridView$ctl02$ctl00\" checked=\"checked\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span title=\"Dummy\"><input id=\"gridView_ctl00_1\" type=\"checkbox\" name=\"gridView$ctl03$ctl00\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span title=\"Dummy\"><input id=\"gridView_ctl00_2\" type=\"checkbox\" name=\"gridView$ctl04$ctl00\" /></span></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span title=\"Dummy\"><input id=\"gridView_ctl02_ctl00\" type=\"checkbox\" name=\"gridView$ctl02$ctl00\" checked=\"checked\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span title=\"Dummy\"><input id=\"gridView_ctl03_ctl00\" type=\"checkbox\" name=\"gridView$ctl03$ctl00\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span title=\"Dummy\"><input id=\"gridView_ctl04_ctl00\" type=\"checkbox\" name=\"gridView$ctl04$ctl00\" /></span></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			WebTest t = new WebTest ("CheckBoxField_Bug595568_0.aspx");
 			string pageHtml = t.Run ();
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHtml);
@@ -142,11 +138,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test (Description="Bug 595568 #1")]
 		public void CheckBoxField_Bug595568_1 ()
 		{
-#if NET_4_0
 			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl02$ctl00\">\r\n\r\n\t\t\t</select><span title=\"Dummy\"><input id=\"gridView_ctl01_0\" type=\"checkbox\" name=\"gridView$ctl02$ctl01\" checked=\"checked\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl03$ctl00\">\r\n\r\n\t\t\t</select><span title=\"Dummy\"><input id=\"gridView_ctl01_1\" type=\"checkbox\" name=\"gridView$ctl03$ctl01\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl04$ctl00\">\r\n\r\n\t\t\t</select><span title=\"Dummy\"><input id=\"gridView_ctl01_2\" type=\"checkbox\" name=\"gridView$ctl04$ctl01\" /></span></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl02$ctl00\">\r\n\r\n\t\t\t</select><span title=\"Dummy\"><input id=\"gridView_ctl02_ctl01\" type=\"checkbox\" name=\"gridView$ctl02$ctl01\" checked=\"checked\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl03$ctl00\">\r\n\r\n\t\t\t</select><span title=\"Dummy\"><input id=\"gridView_ctl03_ctl01\" type=\"checkbox\" name=\"gridView$ctl03$ctl01\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl04$ctl00\">\r\n\r\n\t\t\t</select><span title=\"Dummy\"><input id=\"gridView_ctl04_ctl01\" type=\"checkbox\" name=\"gridView$ctl04$ctl01\" /></span></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			WebTest t = new WebTest ("CheckBoxField_Bug595568_1.aspx");
 			string pageHtml = t.Run ();
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHtml);
@@ -157,11 +149,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test (Description="Bug 595568 #2")]
 		public void CheckBoxField_Bug595568_2 ()
 		{
-#if NET_4_0
 			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl00_0\" type=\"checkbox\" name=\"gridView$ctl02$ctl00\" /><span title=\"Dummy\"><input id=\"gridView_ctl01_0\" type=\"checkbox\" name=\"gridView$ctl02$ctl01\" checked=\"checked\" /></span><input id=\"gridView_ctl02_0\" type=\"checkbox\" name=\"gridView$ctl02$ctl02\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl00_1\" type=\"checkbox\" name=\"gridView$ctl03$ctl00\" /><span title=\"Dummy\"><input id=\"gridView_ctl01_1\" type=\"checkbox\" name=\"gridView$ctl03$ctl01\" /></span><input id=\"gridView_ctl02_1\" type=\"checkbox\" name=\"gridView$ctl03$ctl02\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl00_2\" type=\"checkbox\" name=\"gridView$ctl04$ctl00\" /><span title=\"Dummy\"><input id=\"gridView_ctl01_2\" type=\"checkbox\" name=\"gridView$ctl04$ctl01\" /></span><input id=\"gridView_ctl02_2\" type=\"checkbox\" name=\"gridView$ctl04$ctl02\" /></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl02_ctl00\" type=\"checkbox\" name=\"gridView$ctl02$ctl00\" /><span title=\"Dummy\"><input id=\"gridView_ctl02_ctl01\" type=\"checkbox\" name=\"gridView$ctl02$ctl01\" checked=\"checked\" /></span><input id=\"gridView_ctl02_ctl02\" type=\"checkbox\" name=\"gridView$ctl02$ctl02\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl03_ctl00\" type=\"checkbox\" name=\"gridView$ctl03$ctl00\" /><span title=\"Dummy\"><input id=\"gridView_ctl03_ctl01\" type=\"checkbox\" name=\"gridView$ctl03$ctl01\" /></span><input id=\"gridView_ctl03_ctl02\" type=\"checkbox\" name=\"gridView$ctl03$ctl02\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl04_ctl00\" type=\"checkbox\" name=\"gridView$ctl04$ctl00\" /><span title=\"Dummy\"><input id=\"gridView_ctl04_ctl01\" type=\"checkbox\" name=\"gridView$ctl04$ctl01\" /></span><input id=\"gridView_ctl04_ctl02\" type=\"checkbox\" name=\"gridView$ctl04$ctl02\" /></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			
 			WebTest t = new WebTest ("CheckBoxField_Bug595568_2.aspx");
 			string pageHtml = t.Run ();
@@ -185,11 +173,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test (Description="Bug 595568 #6")]
 		public void CheckBoxField_Bug595568_6 ()
 		{	
-#if NET_4_0
 			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl02$ctl00\">\r\n\r\n\t\t\t</select><input id=\"gridView_ctl01_0\" type=\"checkbox\" name=\"gridView$ctl02$ctl01\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl03$ctl00\">\r\n\r\n\t\t\t</select><input id=\"gridView_ctl01_1\" type=\"checkbox\" name=\"gridView$ctl03$ctl01\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl04$ctl00\">\r\n\r\n\t\t\t</select><input id=\"gridView_ctl01_2\" type=\"checkbox\" name=\"gridView$ctl04$ctl01\" /></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl02$ctl00\">\r\n\r\n\t\t\t</select><input id=\"gridView_ctl02_ctl01\" type=\"checkbox\" name=\"gridView$ctl02$ctl01\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl03$ctl00\">\r\n\r\n\t\t\t</select><input id=\"gridView_ctl03_ctl01\" type=\"checkbox\" name=\"gridView$ctl03$ctl01\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><select size=\"4\" name=\"gridView$ctl04$ctl00\">\r\n\r\n\t\t\t</select><input id=\"gridView_ctl04_ctl01\" type=\"checkbox\" name=\"gridView$ctl04$ctl01\" /></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 
 			WebTest t = new WebTest ("CheckBoxField_Bug595568_6.aspx");
 			string pageHtml = t.Run ();
@@ -201,11 +185,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test (Description="Bug 595568 #7")]
 		public void CheckBoxField_Bug595568_7 ()
 		{
-#if NET_4_0
 			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl00_0\" type=\"checkbox\" name=\"gridView$ctl02$ctl00\" /><select size=\"4\" name=\"gridView$ctl02$ctl01\">\r\n\r\n\t\t\t</select></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl00_1\" type=\"checkbox\" name=\"gridView$ctl03$ctl00\" /><select size=\"4\" name=\"gridView$ctl03$ctl01\">\r\n\r\n\t\t\t</select></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl00_2\" type=\"checkbox\" name=\"gridView$ctl04$ctl00\" /><select size=\"4\" name=\"gridView$ctl04$ctl01\">\r\n\r\n\t\t\t</select></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string originalHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"gridView\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">&nbsp;</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl02_ctl00\" type=\"checkbox\" name=\"gridView$ctl02$ctl00\" /><select size=\"4\" name=\"gridView$ctl02$ctl01\">\r\n\r\n\t\t\t</select></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl03_ctl00\" type=\"checkbox\" name=\"gridView$ctl03$ctl00\" /><select size=\"4\" name=\"gridView$ctl03$ctl01\">\r\n\r\n\t\t\t</select></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input id=\"gridView_ctl04_ctl00\" type=\"checkbox\" name=\"gridView$ctl04$ctl00\" /><select size=\"4\" name=\"gridView$ctl04$ctl01\">\r\n\r\n\t\t\t</select></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			WebTest t = new WebTest ("CheckBoxField_Bug595568_7.aspx");		
 			string pageHtml = t.Run ();
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHtml);

+ 0 - 51
mcs/class/System.Web/Test/System.Web.UI.WebControls/CheckBoxListTest.cs

@@ -160,13 +160,8 @@ namespace MonoTests.System.Web.UI.WebControls {
 		{
 			WebTest t = new WebTest ("CheckBoxList_Bug377703_1.aspx");
 			t.Invoker = PageInvoker.CreateOnInit (CheckBoxList_Bug377703_1_OnInit);
-#if NET_4_0
 			string origHtmlFirst = "<table id=\"cbxl1\">\r\n\t<tr>\r\n\t\t<td><input id=\"cbxl1_0\" type=\"checkbox\" name=\"cbxl1$0\" value=\"x\" /><label for=\"cbxl1_0\">x</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_1\" type=\"checkbox\" name=\"cbxl1$1\" value=\"y\" /><label for=\"cbxl1_1\">y</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_2\" type=\"checkbox\" name=\"cbxl1$2\" value=\"z\" /><label for=\"cbxl1_2\">z</label></td>\r\n\t</tr>\r\n</table>";
 			string origHtmlSecond = "<table id=\"cbxl1\">\r\n\t<tr>\r\n\t\t<td><input id=\"cbxl1_0\" type=\"checkbox\" name=\"cbxl1$0\" checked=\"checked\" value=\"x\" /><label for=\"cbxl1_0\">x</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_1\" type=\"checkbox\" name=\"cbxl1$1\" value=\"y\" /><label for=\"cbxl1_1\">y</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_2\" type=\"checkbox\" name=\"cbxl1$2\" value=\"z\" /><label for=\"cbxl1_2\">z</label></td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtmlFirst = "<table id=\"cbxl1\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><input id=\"cbxl1_0\" type=\"checkbox\" name=\"cbxl1$0\" /><label for=\"cbxl1_0\">x</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_1\" type=\"checkbox\" name=\"cbxl1$1\" /><label for=\"cbxl1_1\">y</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_2\" type=\"checkbox\" name=\"cbxl1$2\" /><label for=\"cbxl1_2\">z</label></td>\r\n\t</tr>\r\n</table>";
-			string origHtmlSecond = "<table id=\"cbxl1\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><input id=\"cbxl1_0\" type=\"checkbox\" name=\"cbxl1$0\" checked=\"checked\" /><label for=\"cbxl1_0\">x</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_1\" type=\"checkbox\" name=\"cbxl1$1\" /><label for=\"cbxl1_1\">y</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl1_2\" type=\"checkbox\" name=\"cbxl1$2\" /><label for=\"cbxl1_2\">z</label></td>\r\n\t</tr>\r\n</table>";
-#endif
 			string html = t.Run ();
 			string listHtml = HtmlDiff.GetControlFromPageHtml (html);
 
@@ -215,15 +210,9 @@ namespace MonoTests.System.Web.UI.WebControls {
 		{
 			WebTest t = new WebTest ("CheckBoxList_Bug377703_2.aspx");
 			t.Invoker = PageInvoker.CreateOnInit (CheckBoxList_Bug377703_2_OnInit);
-#if NET_4_0
 			string origHtmlFirst = "<table id=\"cbxl2\">\r\n\t<tr>\r\n\t\t<td><input id=\"cbxl2_0\" type=\"checkbox\" name=\"cbxl2$0\" value=\"x\" /><label for=\"cbxl2_0\">x</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl2_1\" type=\"checkbox\" name=\"cbxl2$1\" value=\"y\" /><label for=\"cbxl2_1\">y</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl2_2\" type=\"checkbox\" name=\"cbxl2$2\" value=\"z\" /><label for=\"cbxl2_2\">z</label></td>\r\n\t</tr>\r\n</table>";
 			string origHtmlSecond = "<table id=\"cbxl2\" class=\"aspNetDisabled\">\r\n\t<tr>\r\n\t\t<td><span class=\"aspNetDisabled\"><input id=\"cbxl2_0\" type=\"checkbox\" name=\"cbxl2$0\" checked=\"checked\" disabled=\"disabled\" value=\"x\" /><label for=\"cbxl2_0\">x</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span class=\"aspNetDisabled\"><input id=\"cbxl2_1\" type=\"checkbox\" name=\"cbxl2$1\" disabled=\"disabled\" value=\"y\" /><label for=\"cbxl2_1\">y</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span class=\"aspNetDisabled\"><input id=\"cbxl2_2\" type=\"checkbox\" name=\"cbxl2$2\" checked=\"checked\" disabled=\"disabled\" value=\"z\" /><label for=\"cbxl2_2\">z</label></span></td>\r\n\t</tr>\r\n</table>";
 			string origHtmlThird = "<table id=\"cbxl2\" class=\"aspNetDisabled\">\r\n\t<tr>\r\n\t\t<td><span class=\"aspNetDisabled\"><input id=\"cbxl2_0\" type=\"checkbox\" name=\"cbxl2$0\" checked=\"checked\" disabled=\"disabled\" value=\"x\" /><label for=\"cbxl2_0\">x</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span class=\"aspNetDisabled\"><input id=\"cbxl2_1\" type=\"checkbox\" name=\"cbxl2$1\" disabled=\"disabled\" value=\"y\" /><label for=\"cbxl2_1\">y</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span class=\"aspNetDisabled\"><input id=\"cbxl2_2\" type=\"checkbox\" name=\"cbxl2$2\" checked=\"checked\" disabled=\"disabled\" value=\"z\" /><label for=\"cbxl2_2\">z</label></span></td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtmlFirst = "<table id=\"cbxl2\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><input id=\"cbxl2_0\" type=\"checkbox\" name=\"cbxl2$0\" /><label for=\"cbxl2_0\">x</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl2_1\" type=\"checkbox\" name=\"cbxl2$1\" /><label for=\"cbxl2_1\">y</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"cbxl2_2\" type=\"checkbox\" name=\"cbxl2$2\" /><label for=\"cbxl2_2\">z</label></td>\r\n\t</tr>\r\n</table>";
-			string origHtmlSecond = "<table id=\"cbxl2\" disabled=\"disabled\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><span disabled=\"disabled\"><input id=\"cbxl2_0\" type=\"checkbox\" name=\"cbxl2$0\" checked=\"checked\" disabled=\"disabled\" /><label for=\"cbxl2_0\">x</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span disabled=\"disabled\"><input id=\"cbxl2_1\" type=\"checkbox\" name=\"cbxl2$1\" disabled=\"disabled\" /><label for=\"cbxl2_1\">y</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span disabled=\"disabled\"><input id=\"cbxl2_2\" type=\"checkbox\" name=\"cbxl2$2\" checked=\"checked\" disabled=\"disabled\" /><label for=\"cbxl2_2\">z</label></span></td>\r\n\t</tr>\r\n</table>";
-			string origHtmlThird = "<table id=\"cbxl2\" disabled=\"disabled\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><span disabled=\"disabled\"><input id=\"cbxl2_0\" type=\"checkbox\" name=\"cbxl2$0\" checked=\"checked\" disabled=\"disabled\" /><label for=\"cbxl2_0\">x</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span disabled=\"disabled\"><input id=\"cbxl2_1\" type=\"checkbox\" name=\"cbxl2$1\" disabled=\"disabled\" /><label for=\"cbxl2_1\">y</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span disabled=\"disabled\"><input id=\"cbxl2_2\" type=\"checkbox\" name=\"cbxl2$2\" checked=\"checked\" disabled=\"disabled\" /><label for=\"cbxl2_2\">z</label></span></td>\r\n\t</tr>\r\n</table>";
-#endif
 			string html = t.Run ();
 			string listHtml = HtmlDiff.GetControlFromPageHtml (html);
 
@@ -276,11 +265,7 @@ namespace MonoTests.System.Web.UI.WebControls {
 		{
 			WebTest t = new WebTest ("CheckBoxList_Bug578770.aspx");
 			t.Invoker = PageInvoker.CreateOnInit (CheckBoxList_Bug578770_OnInit);
-#if NET_4_0
 			string origHtml = "<table id=\"test\">\r\n\t<tr>\r\n\t\t<td><span class=\"aspNetDisabled\"><input id=\"test_0\" type=\"checkbox\" name=\"test$0\" disabled=\"disabled\" value=\"Sun\" /><label for=\"test_0\">Sun</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span><input id=\"test_1\" type=\"checkbox\" name=\"test$1\" value=\"Mon\" /><label for=\"test_1\">Mon</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span><input id=\"test_2\" type=\"checkbox\" name=\"test$2\" value=\"Tue\" /><label for=\"test_2\">Tue</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span><input id=\"test_3\" type=\"checkbox\" name=\"test$3\" value=\"Wed\" /><label for=\"test_3\">Wed</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span><input id=\"test_4\" type=\"checkbox\" name=\"test$4\" value=\"Thu\" /><label for=\"test_4\">Thu</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span><input id=\"test_5\" type=\"checkbox\" name=\"test$5\" value=\"Fri\" /><label for=\"test_5\">Fri</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><span><input id=\"test_6\" type=\"checkbox\" name=\"test$6\" value=\"Sat\" /><label for=\"test_6\">Sat</label></span></td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtml = "<table id=\"test\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><span disabled=\"disabled\"><input id=\"test_0\" type=\"checkbox\" name=\"test$0\" disabled=\"disabled\" /><label for=\"test_0\">Sun</label></span></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"test_1\" type=\"checkbox\" name=\"test$1\" /><label for=\"test_1\">Mon</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"test_2\" type=\"checkbox\" name=\"test$2\" /><label for=\"test_2\">Tue</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"test_3\" type=\"checkbox\" name=\"test$3\" /><label for=\"test_3\">Wed</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"test_4\" type=\"checkbox\" name=\"test$4\" /><label for=\"test_4\">Thu</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"test_5\" type=\"checkbox\" name=\"test$5\" /><label for=\"test_5\">Fri</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"test_6\" type=\"checkbox\" name=\"test$6\" /><label for=\"test_6\">Sat</label></td>\r\n\t</tr>\r\n</table>";
-#endif
 			string html = t.Run ();
 			string listHtml = HtmlDiff.GetControlFromPageHtml (html);
 
@@ -300,15 +285,9 @@ namespace MonoTests.System.Web.UI.WebControls {
 		public void CheckBoxList_Bug600415 ()
 		{
 			WebTest t = new WebTest ("CheckBoxList_Bug600415.aspx");
-#if NET_4_0
 			string origHtmlFirst = "<table id=\"checkBoxList\">\r\n\t<tr>\r\n\t\t<td><input id=\"checkBoxList_0\" type=\"checkbox\" name=\"checkBoxList$0\" checked=\"checked\" value=\"Item 1\" /><label for=\"checkBoxList_0\">Item 1</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_1\" type=\"checkbox\" name=\"checkBoxList$1\" value=\"Item 2\" /><label for=\"checkBoxList_1\">Item 2</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_2\" type=\"checkbox\" name=\"checkBoxList$2\" checked=\"checked\" value=\"Item 3\" /><label for=\"checkBoxList_2\">Item 3</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_3\" type=\"checkbox\" name=\"checkBoxList$3\" value=\"Item 4\" /><label for=\"checkBoxList_3\">Item 4</label></td>\r\n\t</tr>\r\n</table>";
 			string origHtmlSecond = "<table id=\"checkBoxList\">\r\n\t<tr>\r\n\t\t<td><input id=\"checkBoxList_0\" type=\"checkbox\" name=\"checkBoxList$0\" value=\"Item 1\" /><label for=\"checkBoxList_0\">Item 1</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_1\" type=\"checkbox\" name=\"checkBoxList$1\" value=\"Item 2\" /><label for=\"checkBoxList_1\">Item 2</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_2\" type=\"checkbox\" name=\"checkBoxList$2\" value=\"Item 3\" /><label for=\"checkBoxList_2\">Item 3</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_3\" type=\"checkbox\" name=\"checkBoxList$3\" value=\"Item 4\" /><label for=\"checkBoxList_3\">Item 4</label></td>\r\n\t</tr>\r\n</table>";
 			string origHtmlThird = "<table id=\"checkBoxList\">\r\n\t<tr>\r\n\t\t<td><input id=\"checkBoxList_0\" type=\"checkbox\" name=\"checkBoxList$0\" checked=\"checked\" value=\"Item 1\" /><label for=\"checkBoxList_0\">Item 1</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_1\" type=\"checkbox\" name=\"checkBoxList$1\" checked=\"checked\" value=\"Item 2\" /><label for=\"checkBoxList_1\">Item 2</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_2\" type=\"checkbox\" name=\"checkBoxList$2\" checked=\"checked\" value=\"Item 3\" /><label for=\"checkBoxList_2\">Item 3</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_3\" type=\"checkbox\" name=\"checkBoxList$3\" checked=\"checked\" value=\"Item 4\" /><label for=\"checkBoxList_3\">Item 4</label></td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtmlFirst = "<table id=\"checkBoxList\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><input id=\"checkBoxList_0\" type=\"checkbox\" name=\"checkBoxList$0\" checked=\"checked\" /><label for=\"checkBoxList_0\">Item 1</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_1\" type=\"checkbox\" name=\"checkBoxList$1\" /><label for=\"checkBoxList_1\">Item 2</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_2\" type=\"checkbox\" name=\"checkBoxList$2\" checked=\"checked\" /><label for=\"checkBoxList_2\">Item 3</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_3\" type=\"checkbox\" name=\"checkBoxList$3\" /><label for=\"checkBoxList_3\">Item 4</label></td>\r\n\t</tr>\r\n</table>";
-			string origHtmlSecond = "<table id=\"checkBoxList\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><input id=\"checkBoxList_0\" type=\"checkbox\" name=\"checkBoxList$0\" /><label for=\"checkBoxList_0\">Item 1</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_1\" type=\"checkbox\" name=\"checkBoxList$1\" /><label for=\"checkBoxList_1\">Item 2</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_2\" type=\"checkbox\" name=\"checkBoxList$2\" /><label for=\"checkBoxList_2\">Item 3</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_3\" type=\"checkbox\" name=\"checkBoxList$3\" /><label for=\"checkBoxList_3\">Item 4</label></td>\r\n\t</tr>\r\n</table>";
-			string origHtmlThird = "<table id=\"checkBoxList\" border=\"0\">\r\n\t<tr>\r\n\t\t<td><input id=\"checkBoxList_0\" type=\"checkbox\" name=\"checkBoxList$0\" checked=\"checked\" /><label for=\"checkBoxList_0\">Item 1</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_1\" type=\"checkbox\" name=\"checkBoxList$1\" checked=\"checked\" /><label for=\"checkBoxList_1\">Item 2</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_2\" type=\"checkbox\" name=\"checkBoxList$2\" checked=\"checked\" /><label for=\"checkBoxList_2\">Item 3</label></td>\r\n\t</tr><tr>\r\n\t\t<td><input id=\"checkBoxList_3\" type=\"checkbox\" name=\"checkBoxList$3\" checked=\"checked\" /><label for=\"checkBoxList_3\">Item 4</label></td>\r\n\t</tr>\r\n</table>";
-#endif
 			string html = t.Run ();
 			string listHtml = HtmlDiff.GetControlFromPageHtml (html);
 
@@ -386,13 +365,8 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Test]
 		public void RenderItem ()
 		{
-#if NET_4_0
 			string origHtml1 = "<input id=\"0\" type=\"checkbox\" name=\"0\" value=\"value1\" /><label for=\"0\">item1</label>";
 			string origHtml2 = "<input id=\"1\" type=\"checkbox\" name=\"1\" value=\"value2\" /><label for=\"1\">item2</label>";
-#else
-			string origHtml1 = "<input id=\"0\" type=\"checkbox\" name=\"0\" /><label for=\"0\">item1</label>";
-			string origHtml2 = "<input id=\"1\" type=\"checkbox\" name=\"1\" /><label for=\"1\">item2</label>";
-#endif
 			CheckBoxListPoker c = new CheckBoxListPoker ();
 			ListItem l1 = new ListItem ("item1", "value1");
 			ListItem l2 = new ListItem ("item2", "value2");
@@ -561,11 +535,7 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Test]
 		public void RepeatInfoRenderItem ()
 		{
-#if NET_4_0
 			string origHtml = "<input id=\"0\" type=\"checkbox\" name=\"0\" value=\"one\" /><label for=\"0\">one</label>";
-#else
-			string origHtml = "<input id=\"0\" type=\"checkbox\" name=\"0\" /><label for=\"0\">one</label>";
-#endif
 			StringWriter sw = new StringWriter ();
 			HtmlTextWriter tw = new HtmlTextWriter (sw);
 			CheckBoxList c = new CheckBoxList ();
@@ -640,13 +610,8 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Category("NotDotNet")] // MS's implementation throws NRE's from these
 		public void Render ()
 		{
-#if NET_4_0
 			string origHtml1 = "<table>\n\t<tr>\n\t\t<td><input id=\"0\" name=\"0\" type=\"checkbox\" value=\"foo\"/><label for=\"0\">foo</label></td>\n\t</tr>\n</table>";
 			string origHtml2 = "<table>\n\t<tr>\n\t\t<td><input id=\"0\" name=\"0\" type=\"checkbox\" value=\"foo\"/><label for=\"0\">foo</label></td>\n\t</tr>\n</table>";
-#else
-			string origHtml1 = "<table border=\"0\">\n\t<tr>\n\t\t<td><input id=\"0\" name=\"0\" type=\"checkbox\" /><label for=\"0\">foo</label></td>\n\t</tr>\n</table>";
-			string origHtml2 = "<table border=\"0\">\n\t<tr>\n\t\t<td><input id=\"0\" name=\"0\" type=\"checkbox\" /><label for=\"0\">foo</label></td>\n\t</tr>\n</table>";
-#endif
 			CheckBoxList c;
 			c = new CheckBoxList ();
 			c.Items.Add ("foo");
@@ -666,19 +631,11 @@ namespace MonoTests.System.Web.UI.WebControls {
 			CheckBoxList c = new CheckBoxList ();
 			c.TabIndex = 5;
 			c.Items.Add ("Item1");
-#if NET_4_0
 			string exp = @"<table>
 	<tr>
 		<td><input id=""0"" name=""0"" tabindex=""5"" type=""checkbox"" value=""Item1""/><label for=""0"">Item1</label></td>
 	</tr>
 </table>";
-#else
-			string exp = @"<table border=""0"">
-	<tr>
-		<td><input id=""0"" name=""0"" tabindex=""5"" type=""checkbox"" /><label for=""0"">Item1</label></td>
-	</tr>
-</table>";
-#endif
 			Render (c, exp, "B1");
 		}
 
@@ -690,19 +647,11 @@ namespace MonoTests.System.Web.UI.WebControls {
 			CheckBoxList c = new CheckBoxList ();
 			c.Enabled = false;
 			c.Items.Add ("Item1");
-#if NET_4_0
 			string exp = @"<table class=""aspNetDisabled"">
 	<tr>
 		<td><span class=""aspNetDisabled""><input disabled=""disabled"" id=""0"" name=""0"" type=""checkbox"" value=""Item1""/><label for=""0"">Item1</label></span></td>
 	</tr>
 </table>";
-#else
-			string exp = @"<table border=""0"" disabled=""disabled"">
-	<tr>
-		<td><span disabled=""disabled""><input disabled=""disabled"" id=""0"" name=""0"" type=""checkbox"" /><label for=""0"">Item1</label></span></td>
-	</tr>
-</table>";
-#endif
 			Render (c, exp, "C1");
 		}	
 	class TestCheckBoxList : CheckBoxList

+ 0 - 4
mcs/class/System.Web/Test/System.Web.UI.WebControls/CheckBoxTest.cs

@@ -186,11 +186,7 @@ namespace MonoTests.System.Web.UI.WebControls {
 			c.InputAttributes.Add ("value", "value1");
 			c.Text = "Title";
 			c.Checked = true;
-#if NET_4_0
 			string origHtml = "<input id=\"\" type=\"checkbox\" checked=\"checked\" value=\"value1\" /><label for=\"\">Title</label>";
-#else
-			string origHtml = "<input type=\"checkbox\" checked=\"checked\" value=\"value1\" /><label for>Title</label>";
-#endif
 			string html = c.Render ();
 			HtmlDiff.AssertAreEqual (origHtml, html, "#A1");
 		}

File diff suppressed because it is too large
+ 0 - 1
mcs/class/System.Web/Test/System.Web.UI.WebControls/DataGridTest.cs


+ 0 - 2
mcs/class/System.Web/Test/System.Web.UI.WebControls/DataKeyTest.cs

@@ -67,7 +67,6 @@ namespace MonoTests.System.Web.UI.WebControls
 			Assert.AreEqual (2, iDictionary.Count, "AllValuesReferringToKey#1");
 			Assert.AreEqual ("value1", iDictionary[1], "ValueReferringToKey#1");
 		}
-#if NET_4_0
 		[Test]
 		public void DataKey_Equals ()
 		{
@@ -229,6 +228,5 @@ namespace MonoTests.System.Web.UI.WebControls
 			Assert.IsFalse (key1.Equals (key2), "#A17-1");
 			Assert.IsFalse (key2.Equals (key1), "#A17-2");
 		}
-#endif
 	}
 }

+ 0 - 16
mcs/class/System.Web/Test/System.Web.UI.WebControls/DataListItemTest.cs

@@ -241,17 +241,10 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Test]
 		public void Controls_Table ()
 		{
-#if NET_4_0
 			string origHtml1 = "<tr>\n\t<td>mono</td>\n</tr>";
 			string origHtml2 = "<tr>\n\t<td>mono</td>\n</tr>";
 			string origHtml3 = "<table>\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table>";
 			string origHtml4 = "<span><table>\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table></span>";
-#else
-			string origHtml1 = "<tr>\n\t<td>mono</td>\n</tr>";
-			string origHtml2 = "<tr>\n\t<td>mono</td>\n</tr>";
-			string origHtml3 = "<table border=\"0\">\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table>";
-			string origHtml4 = "<span><table border=\"0\">\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table></span>";
-#endif
 			TestDataListItem dli = new TestDataListItem (0, ListItemType.Item);
 			dli.Controls.Add (GetTable ("mono"));
 
@@ -271,17 +264,10 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Test]
 		public void Controls_Table_Dual ()
 		{
-#if NET_4_0
 			string origHtml1 = "<tr>\n\t<td>mono</td>\n</tr>";
 			string origHtml2 = "<tr>\n\t<td>mono</td>\n</tr>";
 			string origHtml3 = "<table>\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table><table>\n\t<tr>\n\t\t<td>monkey</td>\n\t</tr>\n</table>";
 			string origHtml4 = "<span><table>\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table><table>\n\t<tr>\n\t\t<td>monkey</td>\n\t</tr>\n</table></span>";
-#else
-			string origHtml1 = "<tr>\n\t<td>mono</td>\n</tr>";
-			string origHtml2 = "<tr>\n\t<td>mono</td>\n</tr>";
-			string origHtml3 = "<table border=\"0\">\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table><table border=\"0\">\n\t<tr>\n\t\t<td>monkey</td>\n\t</tr>\n</table>";
-			string origHtml4 = "<span><table border=\"0\">\n\t<tr>\n\t\t<td>mono</td>\n\t</tr>\n</table><table border=\"0\">\n\t<tr>\n\t\t<td>monkey</td>\n\t</tr>\n</table></span>";
-#endif
 			TestDataListItem dli = new TestDataListItem (0, ListItemType.Item);
 			dli.Controls.Add (GetTable ("mono"));
 			dli.Controls.Add (GetTable ("monkey"));
@@ -315,7 +301,6 @@ namespace MonoTests.System.Web.UI.WebControls {
 			Assert.AreEqual ("mono", dli.Render (false, true), "Render-Empty-F-T");
 			Assert.AreEqual ("<span>mono</span>", dli.Render (false, false), "Render-Empty-F-F");
 		}
-#if NET_4_0
 		[Test]
 		public void SupportsDisabledAttribute ()
 		{
@@ -329,6 +314,5 @@ namespace MonoTests.System.Web.UI.WebControls {
 			Assert.AreEqual (ver35, p.RenderingCompatibility, "#A2-1");
 			Assert.IsTrue (p.SupportsDisabledAttribute, "#A2-2");
 		}
-#endif
 	}
 }

+ 0 - 2
mcs/class/System.Web/Test/System.Web.UI.WebControls/DataListTest.cs

@@ -322,7 +322,6 @@ namespace MonoTests.System.Web.UI.WebControls {
 
 			Assert.AreEqual (0, dl.Attributes.Count, "Attributes.Count-2");
 		}
-#if NET_4_0
 		[Test]
 		public void RepeatLayout_Lists ()
 		{
@@ -336,7 +335,6 @@ namespace MonoTests.System.Web.UI.WebControls {
 				dl.RepeatLayout = RepeatLayout.UnorderedList;
 			}, "#A2");
 		}
-#endif
 		[Test]
 		public void CleanProperties ()
 		{

+ 0 - 4
mcs/class/System.Web/Test/System.Web.UI.WebControls/DataSourceControlTest.cs

@@ -76,11 +76,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		public void DataSourceControl_DefaultProperty ()
 		{
 			PokerDataSource ds = new PokerDataSource ();
-#if NET_4_0
 			Assert.AreEqual (String.Empty, ds.ClientID, "ClientID");
-#else
-			Assert.AreEqual (null, ds.ClientID, "ClientID");
-#endif
 			Assert.IsNotNull (ds.Controls, "Controls#1");
 			Assert.AreEqual ( 0 , ds.Controls.Count , "Controls#2");
 			Assert.AreEqual (false, ds.Visible, "Visible");

+ 0 - 56
mcs/class/System.Web/Test/System.Web.UI.WebControls/DetailsViewTest.cs

@@ -634,11 +634,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			t.Request = fr;
 			result = t.Run ();
 			string newHtml = HtmlDiff.GetControlFromPageHtml (result);
-#if NET_4_0
 			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack(&#39;LinkButton1&#39;,&#39;&#39;)\">Test</a>";
-#else
-			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack('LinkButton1','')\">Test</a>";
-#endif
 			HtmlDiff.AssertAreEqual(origHtml, newHtml, "EmptyContentTest");
 		}
 		
@@ -681,11 +677,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			t.Request = fr;
 			result = t.Run ();
 			string newHtml = HtmlDiff.GetControlFromPageHtml (result); 
-#if NET_4_0
 			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack(&#39;LinkButton1&#39;,&#39;&#39;)\">Test</a>";
-#else
-			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack('LinkButton1','')\">Test</a>";
-#endif
 			HtmlDiff.AssertAreEqual(origHtml, newHtml, "EmptyFooterTextTest");
 		}
 		
@@ -727,11 +719,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			t.Request = fr;
 			result = t.Run ();
 			string newHtml = HtmlDiff.GetControlFromPageHtml (result); 
-#if NET_4_0
 			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack(&#39;LinkButton1&#39;,&#39;&#39;)\">Test</a>";
-#else
-			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack('LinkButton1','')\">Test</a>";
-#endif
 			HtmlDiff.AssertAreEqual(origHtml, newHtml, "EmptyHeaderTextTest");
 		}
 		
@@ -770,11 +758,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			//t.Invoker = PageInvoker.CreateOnLoad (pd);
 			result = t.Run ();
 			string newHtml = HtmlDiff.GetControlFromPageHtml (result); 
-#if NET_4_0
 			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>Empty Data</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack(&#39;LinkButton1&#39;,&#39;&#39;)\">Test</a>";
-#else
-			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>Empty Data</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div><a id=\"LinkButton1\" href=\"javascript:__doPostBack('LinkButton1','')\">Test</a>";
-#endif
 			HtmlDiff.AssertAreEqual(origHtml, newHtml, "EmptyDataTextTest");
 		}
 
@@ -879,11 +863,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			string html = new WebTest (PageInvoker.CreateOnLoad (
 				new PageDelegate (DetailsView_DeleteItem))).Run ();
 			string newHtml = HtmlDiff.GetControlFromPageHtml (html);
-#if NET_4_0
 			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1002</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Melanie</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Talmadge</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Page$2&#39;)\">2</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1002</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Melanie</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Talmadge</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('ctl01','Page$2')\">2</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtml, newHtml, "DeleteItemMethod");
 		}
 
@@ -1204,11 +1184,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			Assert.AreEqual (null, tb.Parent, "CreateTable1");
 			Assert.AreEqual (String.Empty, tb.BackImageUrl, "CreateTable2");
 			Assert.AreEqual (0, tb.Rows.Count, "CreateTable3");
-#if NET_4_0
 			Assert.AreEqual (String.Empty, tb.ClientID, "CreateTable3");
-#else
-			Assert.AreEqual (null, tb.ClientID , "CreateTable3");
-#endif
 			dv.ID = "testId"; //private filed _parentID should be set to "testId"			
 			tb = dv.DoCreateTable ();
 			Assert.AreEqual (-1, tb.CellSpacing, "CreateTable4");
@@ -1441,11 +1417,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			//Footer Template property is checked.
 			string renderedPageHtml = new WebTest ("FooterTemplateTest.aspx").Run ();
 			string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
 			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\">\n                Footer Template Test<a id=\"DetailsView1_HyperLink1\">Footer</a>\n            </td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\">\n                Footer Template Test<a id=\"DetailsView1_HyperLink1\">Footer</a>\n            </td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$3')\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";	
-#endif
 
 			HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderFooterTemplate");
 		}
@@ -1457,11 +1429,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			//Header Template property is checked
 			string renderedPageHtml = new WebTest ("DetailsViewTemplates.aspx").Run ();
 			string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
 			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td colspan=\"2\">\n                Header Template<input type=\"submit\" name=\"DetailsView1$Button1\" value=\"Header button\" id=\"DetailsView1_Button1\" />\n            </td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Delete$0&#39;)\">Delete</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td colspan=\"2\">\n                Header Template<input type=\"submit\" name=\"DetailsView1$Button1\" value=\"Header button\" id=\"DetailsView1_Button1\" />\n            </td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack('DetailsView1','Delete$0')\">Delete</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$3')\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderHeaderTemplate");
 		}
 
@@ -1483,11 +1451,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string renderedPageHtml = new WebTest ("DetailsViewTemplates_3.aspx").Run ();
 			string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
 			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView3\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack(&#39;DetailsView3&#39;,&#39;$0&#39;)\">TestButtonField</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td><a></a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Image field</td><td></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Template Field</td><td style=\"background-color:#FFE0C0;\">&nbsp;</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView3&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView3&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView3\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack('DetailsView3','$0')\">TestButtonField</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td><a></a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Image field</td><td></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Template Field</td><td style=\"background-color:#FFE0C0;\">&nbsp;</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('DetailsView3','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('DetailsView3','Page$3')\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 					
 			HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderDataFields");
 		}
@@ -1500,11 +1464,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			t.Invoker = PageInvoker.CreateOnLoad (PagingPostback_Load);
 			string pageHTML = t.Run ();
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Edit$0&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Delete$0&#39;)\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;New$0&#39;)\">New</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Mahesh</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Chand</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack('DetailsView1','Edit$0')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','Delete$0')\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','New$0')\">New</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$3')\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtmlValue, renderedHtml, "BeforePagingDataPostback");
 			FormRequest fr = new FormRequest (t.Response, "form1");
 			fr.Controls.Add ("__EVENTTARGET");
@@ -1514,11 +1474,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			t.Request = fr;
 			pageHTML = t.Run ();
 			renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1002</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Melanie</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Talmadge</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Edit$1&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Delete$1&#39;)\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;New$1&#39;)\">New</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$1&#39;)\">1</a></td><td><span>2</span></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else			
-			origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1002</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Melanie</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Talmadge</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack('DetailsView1','Edit$1')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','Delete$1')\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','New$1')\">New</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><a href=\"javascript:__doPostBack('DetailsView1','Page$1')\">1</a></td><td><span>2</span></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$3')\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtmlValue, renderedHtml, "AfterPagingDataPostback");
 
 			// Checking for change index event fired.
@@ -1589,11 +1545,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			t.Request = fr;			
 			pageHTML = t.Run ();
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td><input name=\"DetailsView1$ctl01\" type=\"text\" value=\"Mahesh\" title=\"FName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td><input name=\"DetailsView1$ctl02\" type=\"text\" value=\"Chand\" title=\"LName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack(&#39;DetailsView1$ctl03&#39;,&#39;&#39;)\">Update</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Cancel$0&#39;)\">Cancel</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1001</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td><input name=\"DetailsView1$ctl01\" type=\"text\" value=\"Mahesh\" title=\"FName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td><input name=\"DetailsView1$ctl02\" type=\"text\" value=\"Chand\" title=\"LName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack('DetailsView1$ctl03','')\">Update</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','Cancel$0')\">Cancel</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$3')\">3</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtmlValue, renderedHtml, "AfterEditPostback");
 			// Checking for change mode event fired.
 			ArrayList eventlist = t.UserData as ArrayList;
@@ -1664,11 +1616,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			pageHTML = t.Run ();
 			//Console.WriteLine ("XXXXFAIL {0}", pageHTML);
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1002</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Melanie</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Talmadge</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Edit$0&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Delete$0&#39;)\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;New$0&#39;)\">New</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Page$2&#39;)\">2</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td>1002</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td>Melanie</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td>Talmadge</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack('DetailsView1','Edit$0')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','Delete$0')\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','New$0')\">New</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('DetailsView1','Page$2')\">2</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 
 			HtmlDiff.AssertAreEqual (origHtmlValue, renderedHtml, "DeleteDataPostback");
 			Assert.AreEqual (false, renderedHtml.Contains ("1001"), "AfterDeletePostback");
@@ -1740,11 +1688,7 @@ namespace MonoTests.System.Web.UI.WebControls
 			t.Request = fr;			
 			pageHTML = t.Run ();
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td><input name=\"DetailsView1$ctl01\" type=\"text\" title=\"ID\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td><input name=\"DetailsView1$ctl02\" type=\"text\" title=\"FName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td><input name=\"DetailsView1$ctl03\" type=\"text\" title=\"LName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack(&#39;DetailsView1$ctl04&#39;,&#39;&#39;)\">Insert</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;DetailsView1&#39;,&#39;Cancel$-1&#39;)\">Cancel</a></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string origHtmlValue = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"DetailsView1\" style=\"height:50px;width:125px;border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<td>ID</td><td><input name=\"DetailsView1$ctl01\" type=\"text\" title=\"ID\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FName</td><td><input name=\"DetailsView1$ctl02\" type=\"text\" title=\"FName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>LName</td><td><input name=\"DetailsView1$ctl03\" type=\"text\" title=\"LName\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td colspan=\"2\"><a href=\"javascript:__doPostBack('DetailsView1$ctl04','')\">Insert</a>&nbsp;<a href=\"javascript:__doPostBack('DetailsView1','Cancel$-1')\">Cancel</a></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";    
-#endif
 
 			HtmlDiff.AssertAreEqual (origHtmlValue, renderedHtml, "InsertDataPostback");
 			

+ 0 - 12
mcs/class/System.Web/Test/System.Web.UI.WebControls/EditCommandColumnTest.cs

@@ -121,11 +121,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test]
 		public void InitializeCell () 
 		{
-#if NET_4_0
 			string origHtml = "<table><tr><td>&nbsp;</td><td>&nbsp;</td><td>one</td><td>two</td><td>three</td></tr><tr><td><a>Edit</a></td><td><input name=\"sucker$ctl02$ctl00\" type=\"submit\" value=\"Bearbeiten\" /></td><td>1</td><td>2</td><td>3</td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr></table>";
-#else
-			string origHtml = "<table border=\"0\"><tr><td>&nbsp;</td><td>&nbsp;</td><td>one</td><td>two</td><td>three</td></tr><tr><td><a>Edit</a></td><td><input name=\"sucker$ctl02$ctl00\" type=\"submit\" value=\"Bearbeiten\" /></td><td>1</td><td>2</td><td>3</td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr></table>";
-#endif
 			DataGridTest	p = new DataGridTest ();
 			DataTable	table = new DataTable ();
 			EditCommandColumn	e;
@@ -170,11 +166,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test]
 		public void ThisIsADGTest () 
 		{
-#if NET_4_0
 			string origHtml = "<table id=\"sucker_tbl\"><tr><td>&nbsp;</td><td>&nbsp;</td><td>one</td><td>two</td><td>three</td></tr><tr><td><a>Edit</a></td><td><input name=\"sucker$ctl02$ctl00\" type=\"submit\" value=\"Bearbeiten\" /></td><td>1</td><td>2</td><td>3</td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr></table>";
-#else
-			string origHtml = "<table border=\"0\" id=\"sucker_tbl\"><tr><td>&nbsp;</td><td>&nbsp;</td><td>one</td><td>two</td><td>three</td></tr><tr><td><a>Edit</a></td><td><input name=\"sucker$ctl02$ctl00\" type=\"submit\" value=\"Bearbeiten\" /></td><td>1</td><td>2</td><td>3</td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr></table>";
-#endif
 			DataGridTest	p = new DataGridTest ();
 			DataTable	table = new DataTable ();
 			EditCommandColumn	e;
@@ -228,11 +220,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test]
 		public void InitializeEditCell () 
 		{
-#if NET_4_0
 			string origHtml = "<table><tr><td>&nbsp;</td><td>&nbsp;</td><td>one</td><td>two</td><td>three</td></tr><tr><td><a>Update</a>&nbsp;<a>Cancel</a></td><td><input name=\"sucker$ctl02$ctl00\" type=\"submit\" value=\"Refresh\" />&nbsp;<input name=\"sucker$ctl02$ctl01\" type=\"submit\" value=\"Abbrechen\" /></td><td><input name=\"sucker$ctl02$ctl02\" type=\"text\" value=\"1\" /></td><td><input name=\"sucker$ctl02$ctl03\" type=\"text\" value=\"2\" /></td><td><input name=\"sucker$ctl02$ctl04\" type=\"text\" value=\"3\" /></td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr></table>";
-#else
-			string origHtml = "<table border=\"0\"><tr><td>&nbsp;</td><td>&nbsp;</td><td>one</td><td>two</td><td>three</td></tr><tr><td><a>Update</a>&nbsp;<a>Cancel</a></td><td><input name=\"sucker$ctl02$ctl00\" type=\"submit\" value=\"Refresh\" />&nbsp;<input name=\"sucker$ctl02$ctl01\" type=\"submit\" value=\"Abbrechen\" /></td><td><input name=\"sucker$ctl02$ctl02\" type=\"text\" value=\"1\" /></td><td><input name=\"sucker$ctl02$ctl03\" type=\"text\" value=\"2\" /></td><td><input name=\"sucker$ctl02$ctl04\" type=\"text\" value=\"3\" /></td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr></table>";
-#endif
 			DataGridTest	p = new DataGridTest ();
 			DataTable	table = new DataTable ();
 			EditCommandColumn	e;

+ 0 - 44
mcs/class/System.Web/Test/System.Web.UI.WebControls/FormViewTest.cs

@@ -349,12 +349,10 @@ namespace MonoTests.System.Web.UI.WebControls
 			public bool GetInitialized () {
 				return Initialized;
 			}
-#if NET_4_0
 			public string CallModifiedOuterTableStylePropertyName ()
 			{
 				return ModifiedOuterTableStylePropertyName ();
 			}
-#endif
 		}
 		
 		class Template : ITemplate
@@ -1570,11 +1568,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 		{
 			string renderedPageHtml = new WebTest ("FormViewTest1.aspx").Run ();
 			string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
 			string origHtmlValue = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView1_Label1\">1</span>\n            </td>\r\n\t</tr><tr align=\"center\" style=\"color:#8C4510;\">\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$2&#39;)\" style=\"color:#8C4510;\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$3&#39;)\" style=\"color:#8C4510;\">3</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$4&#39;)\" style=\"color:#8C4510;\">4</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$5&#39;)\" style=\"color:#8C4510;\">5</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$6&#39;)\" style=\"color:#8C4510;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtmlValue = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" border=\"1\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView1_Label1\">1</span>\n            </td>\r\n\t</tr><tr align=\"center\" style=\"color:#8C4510;\">\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\" style=\"color:#8C4510;\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\" style=\"color:#8C4510;\">3</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$4')\" style=\"color:#8C4510;\">4</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$5')\" style=\"color:#8C4510;\">5</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$6')\" style=\"color:#8C4510;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";         
-#endif
 	
 			HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderSimpleTemplate");                  
 		}
@@ -1585,11 +1579,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 		{
 			string renderedPageHtml = new WebTest ("FormViewTest1_2.aspx").Run ();
 			string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
 			string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"4\" id=\"FormView2\" style=\"color:#333333;border-collapse:collapse;\">\r\n\t<tr style=\"color:#333333;background-color:#F7F6F3;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView2_Label2\">1</span>\n            </td>\r\n\t</tr><tr style=\"color:White;background-color:#5D7B9D;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView2_Label3\">Footer Template Test</span>\n            </td>\r\n\t</tr><tr align=\"center\" style=\"color:White;background-color:#284775;\">\r\n\t\t<td colspan=\"2\">\n                <input type=\"submit\" name=\"FormView2$ctl01$Button1\" value=\"Prev Item\" id=\"FormView2_ctl01_Button1\" />\n                <input type=\"submit\" name=\"FormView2$ctl01$Button2\" value=\"Next Item\" id=\"FormView2_ctl01_Button2\" />\n                <input type=\"submit\" name=\"FormView2$ctl01$Button3\" value=\"First Item\" id=\"FormView2_ctl01_Button3\" />\n                <input type=\"submit\" name=\"FormView2$ctl01$Button4\" value=\"Last Item\" id=\"FormView2_ctl01_Button4\" />\n            </td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"4\" border=\"0\" id=\"FormView2\" style=\"color:#333333;border-collapse:collapse;\">\r\n\t<tr style=\"color:#333333;background-color:#F7F6F3;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView2_Label2\">1</span>\n            </td>\r\n\t</tr><tr style=\"color:White;background-color:#5D7B9D;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView2_Label3\">Footer Template Test</span>\n            </td>\r\n\t</tr><tr align=\"center\" style=\"color:White;background-color:#284775;\">\r\n\t\t<td colspan=\"2\">\n                <input type=\"submit\" name=\"FormView2$ctl01$Button1\" value=\"Prev Item\" id=\"FormView2_ctl01_Button1\" />\n                <input type=\"submit\" name=\"FormView2$ctl01$Button2\" value=\"Next Item\" id=\"FormView2_ctl01_Button2\" />\n                <input type=\"submit\" name=\"FormView2$ctl01$Button3\" value=\"First Item\" id=\"FormView2_ctl01_Button3\" />\n                <input type=\"submit\" name=\"FormView2$ctl01$Button4\" value=\"Last Item\" id=\"FormView2_ctl01_Button4\" />\n            </td>\r\n\t</tr>\r\n</table>";    
-#endif
 			HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "FormView_RenderFooterAndPager");
 		}
 
@@ -1599,11 +1589,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 		{
 			string renderedPageHtml = new WebTest ("FormViewTest1_4.aspx").Run ();
 			string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
 			string origHtmlValue = "<table cellspacing=\"10\" cellpadding=\"3\" align=\"Right\" rules=\"all\" id=\"FormView4\" style=\"background-color:White;border-color:#CCCCCC;border-width:1px;border-style:None;\">\r\n\t<tr align=\"left\" style=\"color:White;background-color:#006699;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">Using Header Text property</td>\r\n\t</tr><tr align=\"center\" style=\"color:#000066;background-color:Maroon;\">\r\n\t\t<td colspan=\"2\">Using Footer Text property</td>\r\n\t</tr><tr align=\"left\" style=\"color:#000066;background-color:LightGrey;\">\r\n\t\t<td colspan=\"2\">\n                <a id=\"FormView4_ctl01_LinkButton1\" href=\"javascript:__doPostBack(&#39;FormView4$ctl01$LinkButton1&#39;,&#39;&#39;)\">Next</a>\n                <a id=\"FormView4_ctl01_LinkButton2\" href=\"javascript:__doPostBack(&#39;FormView4$ctl01$LinkButton2&#39;,&#39;&#39;)\">Prev</a>\n                <span id=\"FormView4_ctl01_Label7\">Page Index: 0</span>\n            </td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtmlValue = "<table cellspacing=\"10\" cellpadding=\"3\" align=\"Right\" rules=\"all\" border=\"1\" id=\"FormView4\" style=\"background-color:White;border-color:#CCCCCC;border-width:1px;border-style:None;\">\r\n\t<tr align=\"left\" style=\"color:White;background-color:#006699;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">Using Header Text property</td>\r\n\t</tr><tr align=\"center\" style=\"color:#000066;background-color:Maroon;\">\r\n\t\t<td colspan=\"2\">Using Footer Text property</td>\r\n\t</tr><tr align=\"left\" style=\"color:#000066;background-color:LightGrey;\">\r\n\t\t<td colspan=\"2\">\n                <a id=\"FormView4_ctl01_LinkButton1\" href=\"javascript:__doPostBack('FormView4$ctl01$LinkButton1','')\">Next</a>\n                <a id=\"FormView4_ctl01_LinkButton2\" href=\"javascript:__doPostBack('FormView4$ctl01$LinkButton2','')\">Prev</a>\n                <span id=\"FormView4_ctl01_Label7\">Page Index: 0</span>\n            </td>\r\n\t</tr>\r\n</table>"; 			
-#endif
 			HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderingDefaultPaging");
 		}
 
@@ -1614,11 +1600,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 		{
 			string RenderedPageHtml = new WebTest ("FormViewTest1_3.aspx").Run ();
 			string newHtmlValue = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"2\" id=\"FormView3\" style=\"color:Black;background-color:LightGoldenrodYellow;border-color:Tan;border-width:1px;border-style:solid;border-collapse:collapse;\">\r\n\t<tr align=\"center\" valign=\"top\" style=\"color:#C00000;background-color:Tan;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView3_Label5\">Header Template Test</span>\n            </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView3_Label4\">1</span>\n            </td>\r\n\t</tr><tr align=\"right\" style=\"color:#FFC0FF;background-color:Tan;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView3_Label6\">FormView Footer</span>\n            </td>\r\n\t</tr><tr align=\"center\" style=\"color:DarkSlateBlue;background-color:PaleGoldenrod;\">\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;FormView3&#39;,&#39;Page$2&#39;)\" style=\"color:DarkSlateBlue;\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView3&#39;,&#39;Page$3&#39;)\" style=\"color:DarkSlateBlue;\">3</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView3&#39;,&#39;Page$4&#39;)\" style=\"color:DarkSlateBlue;\">4</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView3&#39;,&#39;Page$5&#39;)\" style=\"color:DarkSlateBlue;\">5</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView3&#39;,&#39;Page$6&#39;)\" style=\"color:DarkSlateBlue;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"2\" border=\"0\" id=\"FormView3\" style=\"color:Black;background-color:LightGoldenrodYellow;border-color:Tan;border-width:1px;border-style:solid;border-collapse:collapse;\">\r\n\t<tr align=\"center\" valign=\"top\" style=\"color:#C00000;background-color:Tan;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView3_Label5\">Header Template Test</span>\n            </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView3_Label4\">1</span>\n            </td>\r\n\t</tr><tr align=\"right\" style=\"color:#FFC0FF;background-color:Tan;\">\r\n\t\t<td colspan=\"2\">\n                <span id=\"FormView3_Label6\">FormView Footer</span>\n            </td>\r\n\t</tr><tr align=\"center\" style=\"color:DarkSlateBlue;background-color:PaleGoldenrod;\">\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView3','Page$2')\" style=\"color:DarkSlateBlue;\">2</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$3')\" style=\"color:DarkSlateBlue;\">3</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$4')\" style=\"color:DarkSlateBlue;\">4</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$5')\" style=\"color:DarkSlateBlue;\">5</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$6')\" style=\"color:DarkSlateBlue;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";        
-#endif
 			HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderingDefaultPaging");
 		}
 		
@@ -1630,11 +1612,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 			WebTest t = new WebTest ("FormViewInsertEditDelete.aspx");
 			string pageHTML = t.Run ();
 			string newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			string origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    <span id=\"FormView1_ID\">1001</span>&nbsp;\n                    <span id=\"FormView1_LName\">Chand</span>\n                    <span id=\"FormView1_FName\">Mahesh</span>&nbsp;\n                    <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack(&#39;FormView1$EditButton&#39;,&#39;&#39;)\">Edit</a>\n                    <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack(&#39;FormView1$NewButton&#39;,&#39;&#39;)\">New</a>\n                    <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack(&#39;FormView1$DeleteButton&#39;,&#39;&#39;)\">Delete</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    <span id=\"FormView1_ID\">1001</span>&nbsp;\n                    <span id=\"FormView1_LName\">Chand</span>\n                    <span id=\"FormView1_FName\">Mahesh</span>&nbsp;\n                    <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n                    <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n                    <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtml, newHtml, "BeforeEditPostback");
 
 			//Edit button postback (change to edit mode - buttons "Update" and "Cancel" should appear.
@@ -1647,11 +1625,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 			t.Request = fr;
 			pageHTML = t.Run ();
 			newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    Enter First Name:<input name=\"FormView1$FNameEdit\" type=\"text\" value=\"Mahesh\" id=\"FormView1_FNameEdit\" /><br />\n                    Enter Last Name:<input name=\"FormView1$LNameEdit\" type=\"text\" value=\"Chand\" id=\"FormView1_LNameEdit\" /><br />\n                    <a id=\"FormView1_UpdateButton\" href=\"javascript:__doPostBack(&#39;FormView1$UpdateButton&#39;,&#39;&#39;)\">Update</a>\n                    <a id=\"FormView1_CancelUpdateButton\" href=\"javascript:__doPostBack(&#39;FormView1$CancelUpdateButton&#39;,&#39;&#39;)\">Cancel</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
-			origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    Enter First Name:<input name=\"FormView1$FNameEdit\" type=\"text\" value=\"Mahesh\" id=\"FormView1_FNameEdit\" /><br />\n                    Enter Last Name:<input name=\"FormView1$LNameEdit\" type=\"text\" value=\"Chand\" id=\"FormView1_LNameEdit\" /><br />\n                    <a id=\"FormView1_UpdateButton\" href=\"javascript:__doPostBack('FormView1$UpdateButton','')\">Update</a>\n                    <a id=\"FormView1_CancelUpdateButton\" href=\"javascript:__doPostBack('FormView1$CancelUpdateButton','')\">Cancel</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtml, newHtml, "AfterEditPostback");
 
 			//Update record postback                
@@ -1668,11 +1642,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 			t.Request = fr;
 			pageHTML = t.Run ();
 			newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    <span id=\"FormView1_ID\">1001</span>&nbsp;\n                    <span id=\"FormView1_LName\">Test</span>\n                    <span id=\"FormView1_FName\">Merav</span>&nbsp;\n                    <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack(&#39;FormView1$EditButton&#39;,&#39;&#39;)\">Edit</a>\n                    <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack(&#39;FormView1$NewButton&#39;,&#39;&#39;)\">New</a>\n                    <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack(&#39;FormView1$DeleteButton&#39;,&#39;&#39;)\">Delete</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
-			origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    <span id=\"FormView1_ID\">1001</span>&nbsp;\n                    <span id=\"FormView1_LName\">Test</span>\n                    <span id=\"FormView1_FName\">Merav</span>&nbsp;\n                    <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n                    <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n                    <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtml, newHtml, "AfterUpdatePostback"); 
   
 			//Postback to return to Edit mode
@@ -1700,22 +1670,14 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 			t.Request = fr;
 			pageHTML = t.Run ();
 			newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    <span id=\"FormView1_ID\">1001</span>&nbsp;\n                    <span id=\"FormView1_LName\">Test</span>\n                    <span id=\"FormView1_FName\">Merav</span>&nbsp;\n                    <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack(&#39;FormView1$EditButton&#39;,&#39;&#39;)\">Edit</a>\n                    <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack(&#39;FormView1$NewButton&#39;,&#39;&#39;)\">New</a>\n                    <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack(&#39;FormView1$DeleteButton&#39;,&#39;&#39;)\">Delete</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$2&#39;)\">2</a></td><td><a href=\"javascript:__doPostBack(&#39;FormView1&#39;,&#39;Page$3&#39;)\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
-			origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    <span id=\"FormView1_ID\">1001</span>&nbsp;\n                    <span id=\"FormView1_LName\">Test</span>\n                    <span id=\"FormView1_FName\">Merav</span>&nbsp;\n                    <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n                    <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n                    <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n                </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtml, newHtml, "CancelEditedRecordPostback");   
 		}
 
 		[Test (Description="Bug #578863")]
 		public void FormView_PagerSettings_Visibility ()
 		{
-#if NET_4_0
 			string origHtml = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n          <span id=\"FormView1_Label1\">1</span>\n\t</td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtml = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" border=\"1\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n          <span id=\"FormView1_Label1\">1</span>\n\t</td>\r\n\t</tr>\r\n</table>";
-#endif
 			WebTest t = new WebTest ("FormViewPagerVisibility.aspx");
 			string pageHtml = t.Run ();
 			string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHtml);
@@ -2151,11 +2113,7 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 			t.Request = fr;
 			pageHTML = t.Run ();
 			string newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
 			string origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    Insert ID:\n                    <input name=\"FormView1$IDInsert\" type=\"text\" id=\"FormView1_IDInsert\" /><br />\n                    Insert First Name:\n                    <input name=\"FormView1$FNameInsert\" type=\"text\" id=\"FormView1_FNameInsert\" />\n                    <br />\n                    Insert Last Name:&nbsp;\n                    <input name=\"FormView1$LNameInsert\" type=\"text\" id=\"FormView1_LNameInsert\" />\n                    <a id=\"FormView1_InsertButton\" href=\"javascript:__doPostBack(&#39;FormView1$InsertButton&#39;,&#39;&#39;)\">Insert</a>\n                    <a id=\"FormView1_CancelInsertButton\" href=\"javascript:__doPostBack(&#39;FormView1$CancelInsertButton&#39;,&#39;&#39;)\">Cancel</a>\n                </td>\r\n\t</tr>\r\n</table>";
-#else
-			string origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n                    Insert ID:\n                    <input name=\"FormView1$IDInsert\" type=\"text\" id=\"FormView1_IDInsert\" /><br />\n                    Insert First Name:\n                    <input name=\"FormView1$FNameInsert\" type=\"text\" id=\"FormView1_FNameInsert\" />\n                    <br />\n                    Insert Last Name:&nbsp;\n                    <input name=\"FormView1$LNameInsert\" type=\"text\" id=\"FormView1_LNameInsert\" />\n                    <a id=\"FormView1_InsertButton\" href=\"javascript:__doPostBack('FormView1$InsertButton','')\">Insert</a>\n                    <a id=\"FormView1_CancelInsertButton\" href=\"javascript:__doPostBack('FormView1$CancelInsertButton','')\">Cancel</a>\n                </td>\r\n\t</tr>\r\n</table>";
-#endif
 			HtmlDiff.AssertAreEqual (origHtml, newHtml, "InsertPostback");
 
 			//Insert new record
@@ -2418,7 +2376,6 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 		}
 
 		public static void BuildTemplateMethod (Control c) { }
-#if NET_4_0
 		[Test]
 		public void ModifiedOuterTableStylePropertyName ()
 		{
@@ -2471,7 +2428,6 @@ CommandEventArgs cargs = new CommandEventArgs ("Page", "Prev");
 			Assert.IsNotNull (props, "#B1-1");
 			Assert.AreEqual ("BackImageUrl", props, "#B1-2");
 		}
-#endif
 	}
 
 	public class TestMyData

+ 0 - 38
mcs/class/System.Web/Test/System.Web.UI.WebControls/GridViewTest.cs

@@ -591,7 +591,6 @@ namespace MonoTests.System.Web.UI.WebControls
 			g.UseAccessibleHeader = false;
 			Assert.AreEqual (false, g.UseAccessibleHeader, "UseAccessibleHeader");
 		}
-#if NET_4_0
 		[Test]
 		public void SortedAscendingCellStyle ()
 		{
@@ -623,7 +622,6 @@ namespace MonoTests.System.Web.UI.WebControls
 
 			Assert.IsNotNull (g.SortedDescendingHeaderStyle, "#A1-1");
 		}
-#endif
 		[Test]
 		public void GridView_DefaultProtectedProperties ()
 		{
@@ -1596,11 +1594,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderAllowPaging)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">Item</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Norway</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Sweden</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Page$2&#39;)\">2</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">Item</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Norway</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Sweden</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('ctl01','Page$2')\">2</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderDefault");
 		}
 
@@ -1629,11 +1623,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderAllowPaging2)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">Item</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td>France</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Italy</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><table>\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Page$1&#39;)\">1</a></td><td><span>2</span></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Page$3&#39;)\">3</a></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Page$4&#39;)\">4</a></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Page$5&#39;)\">...</a></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Page$Last&#39;)\">&gt;&gt;</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">Item</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td>France</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>Italy</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><table border=\"0\">\r\n\t\t\t\t<tr>\r\n\t\t\t\t\t<td><a href=\"javascript:__doPostBack('ctl01','Page$1')\">1</a></td><td><span>2</span></td><td><a href=\"javascript:__doPostBack('ctl01','Page$3')\">3</a></td><td><a href=\"javascript:__doPostBack('ctl01','Page$4')\">4</a></td><td><a href=\"javascript:__doPostBack('ctl01','Page$5')\">...</a></td><td><a href=\"javascript:__doPostBack('ctl01','Page$Last')\">&gt;&gt;</a></td>\r\n\t\t\t\t</tr>\r\n\t\t\t</table></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderDefault");
 		}
 
@@ -1672,11 +1662,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderProperty)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 				string OriginControlHtml = "<div id=\"__gvctl01__div\">\r\n\t<table cellspacing=\"1\" cellpadding=\"0\" align=\"Justify\" rules=\"rows\" border=\"1\" style=\"background-image:url(http://test);\">\r\n\t\t<caption align=\"Left\">\r\n\t\t\ttest\r\n\t\t</caption><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Edit$0&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Delete$0&#39;)\">Delete</a></td><td>Norway</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Edit$1&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Delete$1&#39;)\">Delete</a></td><td>Sweden</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Edit$2&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Delete$2&#39;)\">Delete</a></td><td>France</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Edit$3&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Delete$3&#39;)\">Delete</a></td><td>Italy</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td>&nbsp;</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div id=\"__gvctl01__div\">\r\n\t<table cellspacing=\"1\" cellpadding=\"0\" align=\"Justify\" rules=\"rows\" border=\"1\" style=\"background-image:url(http://test);\">\r\n\t\t<caption align=\"Left\">\r\n\t\t\ttest\r\n\t\t</caption><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack('ctl01','Edit$0')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Delete$0')\">Delete</a></td><td>Norway</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack('ctl01','Edit$1')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Delete$1')\">Delete</a></td><td>Sweden</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack('ctl01','Edit$2')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Delete$2')\">Delete</a></td><td>France</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack('ctl01','Edit$3')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Delete$3')\">Delete</a></td><td>Italy</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td>&nbsp;</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderDefault");
 		}
 
@@ -1738,11 +1724,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderingCheckBoxField)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span class=\"aspNetDisabled\"><input id=\"ctl01_ctl00_0\" type=\"checkbox\" name=\"ctl01$ctl02$ctl00\" checked=\"checked\" disabled=\"disabled\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span class=\"aspNetDisabled\"><input id=\"ctl01_ctl00_1\" type=\"checkbox\" name=\"ctl01$ctl03$ctl00\" disabled=\"disabled\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span disabled=\"disabled\"><input id=\"ctl01_ctl02_ctl00\" type=\"checkbox\" name=\"ctl01$ctl02$ctl00\" checked=\"checked\" disabled=\"disabled\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span disabled=\"disabled\"><input id=\"ctl01_ctl03_ctl00\" type=\"checkbox\" name=\"ctl01$ctl03$ctl00\" disabled=\"disabled\" /></span></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderingCheckBoxField");
 		}
 
@@ -1751,11 +1733,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderingCheckBoxField2)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">bool</th><th scope=\"col\">str</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span class=\"aspNetDisabled\" title=\"bool\"><input id=\"ctl01_ctl00_0\" type=\"checkbox\" name=\"ctl01$ctl02$ctl00\" checked=\"checked\" disabled=\"disabled\" /></span></td><td>1</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span class=\"aspNetDisabled\" title=\"bool\"><input id=\"ctl01_ctl00_1\" type=\"checkbox\" name=\"ctl01$ctl03$ctl00\" disabled=\"disabled\" /></span></td><td>2</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td>&nbsp;</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">bool</th><th scope=\"col\">str</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span disabled=\"disabled\" title=\"bool\"><input id=\"ctl01_ctl02_ctl00\" type=\"checkbox\" name=\"ctl01$ctl02$ctl00\" checked=\"checked\" disabled=\"disabled\" /></span></td><td>1</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><span disabled=\"disabled\" title=\"bool\"><input id=\"ctl01_ctl03_ctl00\" type=\"checkbox\" name=\"ctl01$ctl03$ctl00\" disabled=\"disabled\" /></span></td><td>2</td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>&nbsp;</td><td>&nbsp;</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderingCheckBoxField2");
 		}
 		
@@ -1764,11 +1742,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderingImageField)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><img src=\"1\" alt=\"1\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><img src=\"2\" alt=\"2\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><img src=\"1\" alt=\"1\" style=\"border-width:0px;\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><img src=\"2\" alt=\"2\" style=\"border-width:0px;\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderingImageField");
 		}
 
@@ -1777,11 +1751,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderingCommandField)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Edit$0&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Delete$0&#39;)\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;New$0&#39;)\">New</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Select$0&#39;)\">Select</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Edit$1&#39;)\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Delete$1&#39;)\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;New$1&#39;)\">New</a>&nbsp;<a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;Select$1&#39;)\">Select</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack('ctl01','Edit$0')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Delete$0')\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','New$0')\">New</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Select$0')\">Select</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><a href=\"javascript:__doPostBack('ctl01','Edit$1')\">Edit</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Delete$1')\">Delete</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','New$1')\">New</a>&nbsp;<a href=\"javascript:__doPostBack('ctl01','Select$1')\">Select</a></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderingCommandField");
 		}
 
@@ -1799,11 +1769,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderingButtonField)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th><th scope=\"col\">HeaderText</th><th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input type=\"button\" value=\"1\" onclick=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;$0&#39;)\" /></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;cmd2$0&#39;)\">1</a></td><td><input type=\"image\" src=\"\" alt=\"1\" onclick=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;cmd3$0&#39;);return false;\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input type=\"button\" value=\"2\" onclick=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;$1&#39;)\" /></td><td><a href=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;cmd2$1&#39;)\">2</a></td><td><input type=\"image\" src=\"\" alt=\"2\" onclick=\"javascript:__doPostBack(&#39;ctl01&#39;,&#39;cmd3$1&#39;);return false;\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td><td>FooterText</td><td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\">HeaderText</th><th scope=\"col\">HeaderText</th><th scope=\"col\">HeaderText</th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input type=\"button\" value=\"1\" onclick=\"javascript:__doPostBack('ctl01','$0')\" /></td><td><a href=\"javascript:__doPostBack('ctl01','cmd2$0')\">1</a></td><td><input type=\"image\" src=\"\" alt=\"1\" onclick=\"javascript:__doPostBack('ctl01','cmd3$0')\" style=\"border-width:0px;\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input type=\"button\" value=\"2\" onclick=\"javascript:__doPostBack('ctl01','$1')\" /></td><td><a href=\"javascript:__doPostBack('ctl01','cmd2$1')\">2</a></td><td><input type=\"image\" src=\"\" alt=\"2\" onclick=\"javascript:__doPostBack('ctl01','cmd3$1')\" style=\"border-width:0px;\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td>FooterText</td><td>FooterText</td><td>FooterText</td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderingButtonField");
 		}
 
@@ -1822,11 +1788,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		{
 			string RenderedPageHtml = new WebTest (PageInvoker.CreateOnLoad (RenderingTemplateField)).Run ();
 			string RenderedControlHtml = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
 			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"grid\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\"><input name=\"grid$ctl01$TextBox1\" type=\"text\" id=\"grid_TextBox1\" /></th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input name=\"grid$ctl02$TextBox1\" type=\"text\" value=\"1\" id=\"grid_TextBox1_0\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input name=\"grid$ctl03$TextBox1\" type=\"text\" value=\"2\" id=\"grid_TextBox1_1\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input name=\"grid$ctl04$TextBox1\" type=\"text\" id=\"grid_TextBox1\" /></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#else
-			string OriginControlHtml = "<div>\r\n\t<table cellspacing=\"0\" rules=\"all\" border=\"1\" id=\"grid\" style=\"border-collapse:collapse;\">\r\n\t\t<tr>\r\n\t\t\t<th scope=\"col\"><input name=\"grid$ctl01$TextBox1\" type=\"text\" id=\"grid_ctl01_TextBox1\" /></th>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input name=\"grid$ctl02$TextBox1\" type=\"text\" value=\"1\" id=\"grid_ctl02_TextBox1\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input name=\"grid$ctl03$TextBox1\" type=\"text\" value=\"2\" id=\"grid_ctl03_TextBox1\" /></td>\r\n\t\t</tr><tr>\r\n\t\t\t<td><input name=\"grid$ctl04$TextBox1\" type=\"text\" id=\"grid_ctl04_TextBox1\" /></td>\r\n\t\t</tr>\r\n\t</table>\r\n</div>";
-#endif
 			HtmlDiff.AssertAreEqual (OriginControlHtml, RenderedControlHtml, "RenderingTemplateField");
 		}
 		

+ 0 - 12
mcs/class/System.Web/Test/System.Web.UI.WebControls/HyperLinkTest.cs

@@ -81,11 +81,7 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Test]
 		public void ImageUrlWithoutText ()
 		{
-#if NET_4_0
 			string origHtml = "<a><img src=\"http://www.mono-project.com/stylesheets/images.wiki.png\" alt=\"\" /></a>";
-#else
-			string origHtml = "<a><img src=\"http://www.mono-project.com/stylesheets/images.wiki.png\" style=\"border-width:0px;\" /></a>";
-#endif
 			TestHyperLink hl = new TestHyperLink ();
 			hl.ImageUrl = imageUrl;
 			Assert.AreEqual (imageUrl, hl.ImageUrl, "ImageUrl");
@@ -101,11 +97,7 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Test]
 		public void ImageUrlWithoutText_ToolTip ()
 		{
-#if NET_4_0
 			string origHtml = "<a title=\"Some message\"><img title=\"Some message\" src=\"http://www.mono-project.com/stylesheets/images.wiki.png\" alt=\"\" /></a>";
-#else
-			string origHtml = "<a title=\"Some message\"><img title=\"Some message\" src=\"http://www.mono-project.com/stylesheets/images.wiki.png\" style=\"border-width:0px;\" /></a>";
-#endif
 			TestHyperLink hl = new TestHyperLink ();
 			hl.ImageUrl = imageUrl;
 			hl.ToolTip = "Some message";
@@ -136,11 +128,7 @@ namespace MonoTests.System.Web.UI.WebControls {
 		[Test]
 		public void ImageUrl_NO_ResolveUrl ()
 		{
-#if NET_4_0
 			string origHtml = "<a><img src=\"~/ben.jpeg\" alt=\"\" /></a>";
-#else
-			string origHtml = "<a><img src=\"~/ben.jpeg\" style=\"border-width:0px;\" /></a>";
-#endif
 			TestHyperLink hl = new TestHyperLink ();
 			hl.ImageUrl = "~/ben.jpeg";
 			Assert.AreEqual ("~/ben.jpeg", hl.ImageUrl, "ImageUrl");

+ 0 - 4
mcs/class/System.Web/Test/System.Web.UI.WebControls/ImageButtonTest.cs

@@ -237,11 +237,7 @@ namespace MonoTests.System.Web.UI.WebControls
 		[Test]
 		public void Text ()
 		{
-#if NET_4_0
 			string origHtml = "<input type=\"image\" src=\"\" alt=\"MyText\" />";
-#else
-			string origHtml = "<input type=\"image\" src=\"\" alt=\"MyText\" style=\"border-width:0px;\" />";
-#endif
 			PokerImageButton b = new PokerImageButton ();
 			b.Text = "MyText";
 			string html = b.Render ();

Some files were not shown because too many files changed in this diff