فهرست منبع

2005-09-21 Sebastien Pouliot <[email protected]>

	* AspNetHostingPermissionTest.cs: 2.0 RC fixed the "unrestricted" XML
	so the test case has been updated.
	* AspNetHostingPermissionAttributeTest.cs: Removed actions that have
	been killed in 2.0 RC.


svn path=/trunk/mcs/; revision=50409
Sebastien Pouliot 20 سال پیش
والد
کامیت
ca12e88640

+ 0 - 8
mcs/class/System/Test/System.Web/AspNetHostingPermissionAttributeTest.cs

@@ -71,14 +71,6 @@ namespace MonoTests.System.Web {
 			Assert.AreEqual (SecurityAction.RequestOptional, a.Action, "Action=RequestOptional");
 			a.Action = SecurityAction.RequestRefuse;
 			Assert.AreEqual (SecurityAction.RequestRefuse, a.Action, "Action=RequestRefuse");
-#if NET_2_0
-			a.Action = SecurityAction.DemandChoice;
-			Assert.AreEqual (SecurityAction.DemandChoice, a.Action, "Action=DemandChoice");
-			a.Action = SecurityAction.InheritanceDemandChoice;
-			Assert.AreEqual (SecurityAction.InheritanceDemandChoice, a.Action, "Action=InheritanceDemandChoice");
-			a.Action = SecurityAction.LinkDemandChoice;
-			Assert.AreEqual (SecurityAction.LinkDemandChoice, a.Action, "Action=LinkDemandChoice");
-#endif
 		}
 
 		[Test]

+ 8 - 5
mcs/class/System/Test/System.Web/AspNetHostingPermissionTest.cs

@@ -5,7 +5,7 @@
 // Author:
 //	Sebastien Pouliot  <[email protected]>
 //
-// Copyright (C) 2004 Novell, Inc (http://www.novell.com)
+// Copyright (C) 2004-2005 Novell, Inc (http://www.novell.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -33,8 +33,6 @@ using System.Security;
 using System.Security.Permissions;
 using System.Web;
 
-//using System.Diagnostics;
-
 namespace MonoTests.System.Web {
 
 	[TestFixture]
@@ -92,8 +90,13 @@ namespace MonoTests.System.Web {
 			Assert.AreEqual (AspNetHostingPermissionLevel.Unrestricted, anhp.Level, "Level");
 			Assert.IsTrue (anhp.IsUnrestricted (), "IsUnrestricted");
 
-			SecurityElement se = anhp.ToXml ();
-			Assert.IsNull (se.Attribute ("Unrestricted"), "Xml-Unrestricted");
+			SecurityElement se = anhp.ToXml ();
+#if NET_2_0
+			// fixed in 2.0 RC
+			Assert.IsNotNull (se.Attribute ("Unrestricted"), "Xml-Unrestricted");
+#else
+			Assert.IsNull (se.Attribute ("Unrestricted"), "Xml-Unrestricted");
+#endif
 			Assert.AreEqual ("Unrestricted", se.Attribute ("Level"), "Xml-Level");
 			Assert.IsNull (se.Children, "Xml-Children");
 

+ 7 - 0
mcs/class/System/Test/System.Web/ChangeLog

@@ -1,3 +1,10 @@
+2005-09-21  Sebastien Pouliot  <[email protected]>
+
+	* AspNetHostingPermissionTest.cs: 2.0 RC fixed the "unrestricted" XML
+	so the test case has been updated.
+	* AspNetHostingPermissionAttributeTest.cs: Removed actions that have
+	been killed in 2.0 RC.
+
 2005-01-19  Sebastien Pouliot  <[email protected]>
 
 	* AspNetHostingPermissionTest.cs: Re-fixed for NET_1_1. Fx 1.1 SP1