Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Köplinger <alex.koeplinger@outlook.com>2017-10-18 03:20:07 +0300
committerGitHub <noreply@github.com>2017-10-18 03:20:07 +0300
commit464c5916d52fea6590bb23cfc84b47e064fc3e66 (patch)
tree82f854da5da696608e1425ab2c4e2be47a98c7c1 /mcs/class/System.IdentityModel
parentafb822af074b6d90a1dd332720e0cee4ca599769 (diff)
[bcl] Fix test assembly build for monodroid profile (#5808)
* [System.IdentityModel] Add excludes for tests that don't compile on monodroid profile Also add a new test for X509CertificateValidator so the assembly isn't empty on monodroid. * [System.ServiceModel] Add excludes for tests that don't compile on monodroid profile * [System.Security] Add excludes for tests that don't compile on monodroid profile Also reduce duplication between common.sources and System.Security.dll.sources * [System.Web.Services] Add excludes for tests that don't compile on monodroid profile * [System.ComponentModel.DataAnnotations] Make tests compile on monodroid profile
Diffstat (limited to 'mcs/class/System.IdentityModel')
-rw-r--r--mcs/class/System.IdentityModel/System.IdentityModel_test.dll.sources1
-rw-r--r--mcs/class/System.IdentityModel/Test/System.IdentityModel.Selectors/X509CertificateValidatorTest.cs45
-rw-r--r--mcs/class/System.IdentityModel/monodroid_System.IdentityModel_test.dll.exclude.sources37
3 files changed, 83 insertions, 0 deletions
diff --git a/mcs/class/System.IdentityModel/System.IdentityModel_test.dll.sources b/mcs/class/System.IdentityModel/System.IdentityModel_test.dll.sources
index 2fcb687a3a5..83cf424100d 100644
--- a/mcs/class/System.IdentityModel/System.IdentityModel_test.dll.sources
+++ b/mcs/class/System.IdentityModel/System.IdentityModel_test.dll.sources
@@ -10,6 +10,7 @@ System.IdentityModel.Selectors/SamlSecurityTokenAuthenticatorTest.cs
System.IdentityModel.Selectors/SecurityTokenRequirementTest.cs
System.IdentityModel.Selectors/SecurityTokenResolverTest.cs
System.IdentityModel.Selectors/TestEvaluationContext.cs
+System.IdentityModel.Selectors/X509CertificateValidatorTest.cs
System.IdentityModel.Selectors/X509SecurityTokenAuthenticatorTest.cs
System.IdentityModel.Selectors/X509SecurityTokenProviderTest.cs
System.IdentityModel.Tokens/BootstrapContextTest.cs
diff --git a/mcs/class/System.IdentityModel/Test/System.IdentityModel.Selectors/X509CertificateValidatorTest.cs b/mcs/class/System.IdentityModel/Test/System.IdentityModel.Selectors/X509CertificateValidatorTest.cs
new file mode 100644
index 00000000000..fb0716f01dd
--- /dev/null
+++ b/mcs/class/System.IdentityModel/Test/System.IdentityModel.Selectors/X509CertificateValidatorTest.cs
@@ -0,0 +1,45 @@
+//
+// X509CertificateValidatorTest.cs
+//
+// Author:
+// Alexander Köplinger <alkpli@microsoft.com>
+//
+// Copyright (C) 2017 Microsoft
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+using System;
+using System.IdentityModel.Selectors;
+using System.Security.Cryptography.X509Certificates;
+using NUnit.Framework;
+
+namespace MonoTests.System.IdentityModel.Selectors
+{
+ [TestFixture]
+ public class X509CertificateValidatorTest
+ {
+ [Test]
+ public void ConstructorTest ()
+ {
+ Assert.NotNull (X509CertificateValidator.CreateChainTrustValidator (false, new X509ChainPolicy ()));
+ Assert.NotNull (X509CertificateValidator.CreatePeerOrChainTrustValidator (false, new X509ChainPolicy ()));
+ }
+ }
+}
diff --git a/mcs/class/System.IdentityModel/monodroid_System.IdentityModel_test.dll.exclude.sources b/mcs/class/System.IdentityModel/monodroid_System.IdentityModel_test.dll.exclude.sources
new file mode 100644
index 00000000000..2fcb687a3a5
--- /dev/null
+++ b/mcs/class/System.IdentityModel/monodroid_System.IdentityModel_test.dll.exclude.sources
@@ -0,0 +1,37 @@
+System.IdentityModel.Claims/ClaimSetTest.cs
+System.IdentityModel.Claims/ClaimTest.cs
+System.IdentityModel.Claims/ClaimTypesTest.cs
+System.IdentityModel.Claims/X509CertificateClaimSetTest.cs
+System.IdentityModel.Common/MySecurityTokenSerializer.cs
+System.IdentityModel.Policy/AuthorizationContextTest.cs
+System.IdentityModel.Selectors/CustomUserNameSecurityTokenAuthenticatorTest.cs
+System.IdentityModel.Selectors/RsaSecurityTokenAuthenticatorTest.cs
+System.IdentityModel.Selectors/SamlSecurityTokenAuthenticatorTest.cs
+System.IdentityModel.Selectors/SecurityTokenRequirementTest.cs
+System.IdentityModel.Selectors/SecurityTokenResolverTest.cs
+System.IdentityModel.Selectors/TestEvaluationContext.cs
+System.IdentityModel.Selectors/X509SecurityTokenAuthenticatorTest.cs
+System.IdentityModel.Selectors/X509SecurityTokenProviderTest.cs
+System.IdentityModel.Tokens/BootstrapContextTest.cs
+System.IdentityModel.Tokens/EncryptedKeyIdentifierClauseTest.cs
+System.IdentityModel.Tokens/InMemorySymmetricSecurityKeyTest.cs
+System.IdentityModel.Tokens/LocalIdKeyIdentifierClauseTest.cs
+System.IdentityModel.Tokens/SamlActionTest.cs
+System.IdentityModel.Tokens/SamlAssertionTest.cs
+System.IdentityModel.Tokens/SamlAttributeStatementTest.cs
+System.IdentityModel.Tokens/SamlAudienceRestrictionConditionTest.cs
+System.IdentityModel.Tokens/SamlAuthenticationStatementTest.cs
+System.IdentityModel.Tokens/SamlAuthorityBindingTest.cs
+System.IdentityModel.Tokens/SamlAuthorizationDecisionStatementTest.cs
+System.IdentityModel.Tokens/SamlConditionsTest.cs
+System.IdentityModel.Tokens/SamlConstantsTest.cs
+System.IdentityModel.Tokens/SamlEvidenceTest.cs
+System.IdentityModel.Tokens/SamlSubjectTest.cs
+System.IdentityModel.Tokens/SecurityAlgorithmsTest.cs
+System.IdentityModel.Tokens/SecurityKeyIdentifierTest.cs
+System.IdentityModel.Tokens/SecurityTokenTypesTest.cs
+System.IdentityModel.Tokens/UserNameSecurityTokenTest.cs
+System.IdentityModel.Tokens/X509AsymmetricSecurityKeyTest.cs
+System.IdentityModel.Tokens/X509IssuerSerialKeyIdentifierClauseTest.cs
+System.IdentityModel.Tokens/X509SecurityTokenTest.cs
+System.IdentityModel.Tokens/X509ThumbprintKeyIdentifierClauseTest.cs