Browse Source

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

	* AspNetHostingMinimal.cs: Rename tests to LinkDemand_* so they have 
	less chances to conflict with tests in derived classes.
	* AspNetHostingPermissionHelper.cs: Made VoidType public.


svn path=/trunk/mcs/; revision=49805
Sebastien Pouliot 20 năm trước cách đây
mục cha
commit
80c3e95508

+ 12 - 12
mcs/class/System.Web/Test/Cas/AspNetHostingMinimal.cs

@@ -38,35 +38,35 @@ namespace MonoCasTests {
 
 		[Test]
 		[AspNetHostingPermission (SecurityAction.PermitOnly, Level = AspNetHostingPermissionLevel.Unrestricted)]
-		public void PermitOnly_Unrestricted ()
+		public void LinkDemand_PermitOnly_Unrestricted ()
 		{
 			Assert.IsNotNull (CreateControl (SecurityAction.PermitOnly, AspNetHostingPermissionLevel.Unrestricted));
 		}
 
 		[Test]
 		[AspNetHostingPermission (SecurityAction.PermitOnly, Level = AspNetHostingPermissionLevel.High)]
-		public void PermitOnly_High ()
+		public void LinkDemand_PermitOnly_High ()
 		{
 			Assert.IsNotNull (CreateControl (SecurityAction.PermitOnly, AspNetHostingPermissionLevel.High));
 		}
 
 		[Test]
 		[AspNetHostingPermission (SecurityAction.PermitOnly, Level = AspNetHostingPermissionLevel.Medium)]
-		public void PermitOnly_Medium ()
+		public void LinkDemand_PermitOnly_Medium ()
 		{
 			Assert.IsNotNull (CreateControl (SecurityAction.PermitOnly, AspNetHostingPermissionLevel.Medium));
 		}
 
 		[Test]
 		[AspNetHostingPermission (SecurityAction.PermitOnly, Level = AspNetHostingPermissionLevel.Low)]
-		public void PermitOnly_Low ()
+		public void LinkDemand_PermitOnly_Low ()
 		{
 			Assert.IsNotNull (CreateControl (SecurityAction.PermitOnly, AspNetHostingPermissionLevel.Low));
 		}
 
 		[Test]
 		[AspNetHostingPermission (SecurityAction.PermitOnly, Level = AspNetHostingPermissionLevel.Minimal)]
-		public void PermitOnly_Minimal ()
+		public void LinkDemand_PermitOnly_Minimal ()
 		{
 			Assert.IsNotNull (CreateControl (SecurityAction.PermitOnly, AspNetHostingPermissionLevel.Minimal));
 		}
@@ -74,7 +74,7 @@ namespace MonoCasTests {
 		[Test]
 		[AspNetHostingPermission (SecurityAction.PermitOnly, Level = AspNetHostingPermissionLevel.None)]
 		[ExpectedException (typeof (SecurityException))]
-		public void PermitOnly_None ()
+		public void LinkDemand_PermitOnly_None ()
 		{
 			CreateControl (SecurityAction.PermitOnly, AspNetHostingPermissionLevel.None);
 		}
@@ -82,7 +82,7 @@ namespace MonoCasTests {
 		[Test]
 		[AspNetHostingPermission (SecurityAction.Deny, Level = AspNetHostingPermissionLevel.Unrestricted)]
 		[ExpectedException (typeof (SecurityException))]
-		public void Deny_Unrestricted ()
+		public void LinkDemand_Deny_Unrestricted ()
 		{
 			CreateControl (SecurityAction.Deny, AspNetHostingPermissionLevel.Unrestricted);
 		}
@@ -90,7 +90,7 @@ namespace MonoCasTests {
 		[Test]
 		[AspNetHostingPermission (SecurityAction.Deny, Level = AspNetHostingPermissionLevel.High)]
 		[ExpectedException (typeof (SecurityException))]
-		public void Deny_High ()
+		public void LinkDemand_Deny_High ()
 		{
 			CreateControl (SecurityAction.Deny, AspNetHostingPermissionLevel.High);
 		}
@@ -98,7 +98,7 @@ namespace MonoCasTests {
 		[Test]
 		[AspNetHostingPermission (SecurityAction.Deny, Level = AspNetHostingPermissionLevel.Medium)]
 		[ExpectedException (typeof (SecurityException))]
-		public void Deny_Medium ()
+		public void LinkDemand_Deny_Medium ()
 		{
 			CreateControl (SecurityAction.Deny, AspNetHostingPermissionLevel.Medium);
 		}
@@ -106,7 +106,7 @@ namespace MonoCasTests {
 		[Test]
 		[AspNetHostingPermission (SecurityAction.Deny, Level = AspNetHostingPermissionLevel.Low)]
 		[ExpectedException (typeof (SecurityException))]
-		public void Deny_Low ()
+		public void LinkDemand_Deny_Low ()
 		{
 			CreateControl (SecurityAction.Deny, AspNetHostingPermissionLevel.Low);
 		}
@@ -114,14 +114,14 @@ namespace MonoCasTests {
 		[Test]
 		[AspNetHostingPermission (SecurityAction.Deny, Level = AspNetHostingPermissionLevel.Minimal)]
 		[ExpectedException (typeof (SecurityException))]
-		public void Deny_Minimal ()
+		public void LinkDemand_Deny_Minimal ()
 		{
 			CreateControl (SecurityAction.Deny, AspNetHostingPermissionLevel.Minimal);
 		}
 
 		[Test]
 		[AspNetHostingPermission (SecurityAction.Deny, Level = AspNetHostingPermissionLevel.None)]
-		public void Deny_None ()
+		public void LinkDemand_Deny_None ()
 		{
 			Assert.IsNotNull (CreateControl (SecurityAction.Deny, AspNetHostingPermissionLevel.None));
 		}

+ 1 - 1
mcs/class/System.Web/Test/Cas/AspNetHostingPermissionHelper.cs

@@ -50,7 +50,7 @@ namespace MonoCasTests {
 		// a LinkDemand (which will be converted into full demand, i.e. a stack walk) 
 		// when reflection is used (i.e. it gets testable).
 
-		static Type[] VoidType = new Type[0];
+		public static Type[] VoidType = new Type[0];
 
 		public virtual object CreateControl (SecurityAction action, AspNetHostingPermissionLevel level)
 		{

+ 6 - 0
mcs/class/System.Web/Test/Cas/ChangeLog

@@ -1,3 +1,9 @@
+2005-09-09  Sebastien Pouliot  <[email protected]>
+
+	* AspNetHostingMinimal.cs: Rename tests to LinkDemand_* so they have 
+	less chances to conflict with tests in derived classes.
+	* AspNetHostingPermissionHelper.cs: Made VoidType public.
+
 2005-09-02  Sebastien Pouliot  <[email protected]>
 
 	* AspNetHostingMinimal.cs: Added new required parameters to all calls