Files
dotnet-runtime/src/libraries/System.Net.ServicePoint/tests/TlsSystemDefault.cs
T
Dan Moseley 3b6739420a Try finalizer on RemoteInvokeHandle (dotnet/corefx#27087)
* Try finalizer on RemoteInvokeHandle

* Adding missing Dispose call to RemoteInvoke's in different test projects

* Fixing tests in System.Diagnostics.Process missing Dispose on RemoteInvokeHandle

* Add missing Dispose call to System.Data.Common.XsdSchemaDeserializationIgnoresLocale()

* Fixing netfx failure in System.Runtime

* Adding missing Dispose call after using RemoteInvokeHandle in System.Net.ServicePoint project


Commit migrated from https://github.com/dotnet/corefx/commit/6ab836db8df5ec9af77063e45f42adccf86ec0b5
2018-02-20 15:34:41 -05:00

25 lines
819 B
C#

// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Diagnostics;
using Xunit;
namespace System.Net.Tests
{
public class TlsSystemDefault : RemoteExecutorTestBase
{
[Fact]
public void ServicePointManager_SecurityProtocolDefault_Ok()
{
RemoteInvoke(() => Assert.Equal(SecurityProtocolType.SystemDefault, ServicePointManager.SecurityProtocol)).Dispose();
}
[Fact]
public void ServicePointManager_CheckAllowedProtocols_SystemDefault_Allowed()
{
RemoteInvoke(() => ServicePointManager.SecurityProtocol = SecurityProtocolType.SystemDefault).Dispose();
}
}
}