{
"name": "ms-test-suite",
"url": "git@github.com:xamarin/ms-test-suite.git",
- "rev": "eb7cd709549bffe170653a50805f1593d66ea81e",
+ "rev": "55b6637eb1de61c743323ec82db1e0cadfee5b32",
"remote-branch": "origin/master",
"branch": "master",
"directory": "ms-test-suite"
"branch": "master",
"directory": "benchmarker"
}
-]
+]
\ No newline at end of file
check-ms-test-suite:
@if $(MAKE) validate-ms-test-suite RESET_VERSIONS=1; then \
- $(MAKE) -C $(MSTESTSUITE_PATH)/conformance build MCS="$(MCS) -debug -t:library -warn:1 -r:nunit.framework" && \
- $(MAKE) -C $(MSTESTSUITE_PATH)/conformance run NUNIT-CONSOLE="$(RUNTIME) $(CLASS)/nunit-console.exe -nologo -exclude=MonoBug,BadTest" NUNIT_XML_RESULT=$(abs_top_builddir)/acceptance-tests/TestResult-ms-test-suite-conformance.xml || EXIT_CODE=1; \
+ $(MAKE) -C $(MSTESTSUITE_PATH)/conformance build MCS="$(MCS) -debug -t:library -warn:1 -r:nunitlite.dll" && \
+ $(MAKE) -C $(MSTESTSUITE_PATH)/conformance run NUNIT-CONSOLE="$(RUNTIME) $(CLASS)/nunit-lite-console.exe -exclude=MonoBug,BadTest -format:nunit2" NUNIT_XML_RESULT="-result:$(abs_top_builddir)/acceptance-tests/TestResult-ms-test-suite-conformance.xml" || EXIT_CODE=1; \
$(MAKE) -C $(MSTESTSUITE_PATH)/systemruntimebringup build MCS="$(MCS) -debug -warn:1" && \
$(MAKE) -C $(MSTESTSUITE_PATH)/systemruntimebringup run MONO="$(RUNTIME)" || EXIT_CODE=1; \
exit $$EXIT_CODE; \
if (IsServer) {
SetPrivateCertificate (nativeServerCertificate);
} else {
- ssl.SetServerName (TargetHost);
+ ssl.SetServerName (ServerName);
}
}
if (!IsServer)
ctx.SetSelectCallback (SelectCallback);
- var host = TargetHost;
- if (!string.IsNullOrEmpty (host)) {
- var pos = TargetHost.IndexOf (':');
- if (pos > 0)
- host = host.Substring (0, pos);
- }
-
- ctx.SetVerifyParam (MonoBtlsProvider.GetVerifyParam (host, IsServer));
+ ctx.SetVerifyParam (MonoBtlsProvider.GetVerifyParam (ServerName, IsServer));
TlsProtocolCode minProtocol, maxProtocol;
GetProtocolVersions (out minProtocol, out maxProtocol);
MobileAuthenticatedStream parent;
bool serverMode;
string targetHost;
+ string serverName;
SslProtocols enabledProtocols;
X509Certificate serverCertificate;
X509CertificateCollection clientCertificates;
this.clientCertificates = clientCertificates;
this.askForClientCert = askForClientCert;
+ serverName = targetHost;
+ if (!string.IsNullOrEmpty (serverName)) {
+ var pos = serverName.IndexOf (':');
+ if (pos > 0)
+ serverName = serverName.Substring (0, pos);
+ }
+
certificateValidator = CertificateValidationHelper.GetInternalValidator (
parent.Settings, parent.Provider);
}
get { return targetHost; }
}
+ protected string ServerName {
+ get { return serverName; }
+ }
+
protected bool AskForClientCertificate {
get { return askForClientCert; }
}
get {
Win32_IP_ADAPTER_INFO ai = Win32NetworkInterface2.GetAdapterInfoByIndex (mib4.Index);
// FIXME: should ipv6 DhcpServer be considered?
- return ai != null ? Win32FromUnicast ((int) ai.Index, addr.FirstUnicastAddress) : new UnicastIPAddressInformationCollection ();
+ return ai != null ? Win32FromUnicast (addr.FirstUnicastAddress) : new UnicastIPAddressInformationCollection ();
}
}
- static UnicastIPAddressInformationCollection Win32FromUnicast (int ifIndex, IntPtr ptr)
+ static UnicastIPAddressInformationCollection Win32FromUnicast (IntPtr ptr)
{
UnicastIPAddressInformationCollection c = new UnicastIPAddressInformationCollection ();
Win32_IP_ADAPTER_UNICAST_ADDRESS a;
for (IntPtr p = ptr; p != IntPtr.Zero; p = a.Next) {
a = (Win32_IP_ADAPTER_UNICAST_ADDRESS) Marshal.PtrToStructure (p, typeof (Win32_IP_ADAPTER_UNICAST_ADDRESS));
- c.InternalAdd (new Win32UnicastIPAddressInformation (ifIndex, a));
+ c.InternalAdd (new Win32UnicastIPAddressInformation (a));
}
return c;
}
using System;
using System.Runtime.InteropServices;
using System.Net.Sockets;
+using System.Diagnostics.Contracts;
namespace System.Net.NetworkInformation {
#if !MOBILE
class Win32UnicastIPAddressInformation : UnicastIPAddressInformation
{
- int if_index;
Win32_IP_ADAPTER_UNICAST_ADDRESS info;
+ IPAddress ipv4Mask;
- public Win32UnicastIPAddressInformation (int ifIndex, Win32_IP_ADAPTER_UNICAST_ADDRESS info)
+ public Win32UnicastIPAddressInformation (Win32_IP_ADAPTER_UNICAST_ADDRESS info)
{
- this.if_index = ifIndex;
this.info = info;
+ IPAddress ipAddress = info.Address.GetIPAddress ();
+ // IPv6 returns 0.0.0.0 for consistancy with XP
+ if (ipAddress.AddressFamily == AddressFamily.InterNetwork) {
+ ipv4Mask = PrefixLengthToSubnetMask (info.OnLinkPrefixLength, ipAddress.AddressFamily);
+ }
}
public override IPAddress Address {
get { return info.DadState; }
}
- public override IPAddress IPv4Mask {
+ public override IPAddress IPv4Mask{
get {
- Win32_IP_ADAPTER_INFO ai = Win32NetworkInterface2.GetAdapterInfoByIndex (if_index);
- if (ai == null)
- throw new Exception ("huh? " + if_index);
- if (this.Address == null)
- return null;
- string expected = this.Address.ToString ();
- unsafe {
- Win32_IP_ADDR_STRING p = ai.IpAddressList;
- while (true) {
- if (p.IpAddress == expected)
- return IPAddress.Parse (p.IpMask);
- if (p.Next == IntPtr.Zero)
- break;
- p = (Win32_IP_ADDR_STRING) Marshal.PtrToStructure (p.Next, typeof (Win32_IP_ADDR_STRING));
- }
-
- // Or whatever it should be...
- return null;
+ // The IPv6 equivilant was never available on XP, and we've kept this behavior for legacy reasons.
+ // For IPv6 use PrefixLength instead.
+ if (Address.AddressFamily != AddressFamily.InterNetwork) {
+ return IPAddress.Any;
}
+
+ return ipv4Mask;
}
}
public override SuffixOrigin SuffixOrigin {
get { return info.SuffixOrigin; }
}
+
+ // Convert a CIDR prefix length to a subnet mask "255.255.255.0" format
+ private static IPAddress PrefixLengthToSubnetMask (byte prefixLength, AddressFamily family) {
+ Contract.Requires ((0 <= prefixLength) && (prefixLength <= 126));
+ Contract.Requires ((family == AddressFamily.InterNetwork) || (family == AddressFamily.InterNetworkV6));
+
+ byte[] addressBytes;
+ if (family == AddressFamily.InterNetwork) {
+ addressBytes = new byte [4];
+ } else { // v6
+ addressBytes = new byte [16];
+ }
+
+ Contract.Assert (prefixLength < (addressBytes.Length * 8));
+
+ // Enable bits one at a time from left/high to right/low
+ for (int bit = 0; bit < prefixLength; bit++) {
+ addressBytes [bit / 8] |= (byte) (0x80 >> (bit % 8));
+ }
+
+ return new IPAddress (addressBytes);
+ }
}
#endif
[STAThread]\r
public static int Main(string[] args)\r
{\r
+ Console.ForegroundColor = ConsoleColor.Red;\r
+ Console.WriteLine ("Note: nunit-console shipped with Mono is deprecated, please use the NUnit NuGet package or some other form of acquiring NUnit.");\r
+ Console.ResetColor ();\r
return Runner.Main( args );\r
}\r
}\r
/// {}\r
/// </example>\r
[AttributeUsage(AttributeTargets.Class, AllowMultiple=false, Inherited=true)]\r
+ [Obsolete ("The NUnit framework shipped with Mono is deprecated and will be removed in a future release. It was based on NUnit 2.4 which is long outdated. Please move to the NUnit NuGet package or some other form of acquiring NUnit.", true)]\r
public class TestFixtureAttribute : Attribute\r
{\r
private string description;\r
int num_array_interfaces;
int is_enumerator = FALSE;
+ mono_loader_lock ();
+
mono_class_setup_supertypes (klass);
/*
* get the implicit generic interfaces for either the arrays or for System.Array/InternalEnumerator<T>
}
/* Publish the data */
- mono_loader_lock ();
-
klass->max_interface_id = max_iid;
/*
* We might get called multiple times:
klass->interface_bitmap = bitmap;
#endif
}
+end:
mono_loader_unlock ();
-end:
g_free (interfaces_full);
g_free (interface_offsets_full);
g_free (array_interfaces);
Mono_Posix_ToSyslogOptions\r
Mono_Posix_ToWaitOptions\r
Mono_Posix_ToXattrFlags\r
+Mono_Unix_VersionString\r
CreateZStream\r
CloseZStream\r
ReadZStream\r
${TESTCMD} --label=System.Data --timeout=5m make -w -C mcs/class/System.Data run-test
${TESTCMD} --label=System.Data.OracleClient --timeout=5m make -w -C mcs/class/System.Data.OracleClient run-test;
${TESTCMD} --label=System.Design --timeout=5m make -w -C mcs/class/System.Design run-test;
-${TESTCMD} --label=Mono.Posix --timeout=5m make -w -C mcs/class/Mono.Posix run-test
+if [[ -n "${ghprbPullId}" ]] && [[ ${label} == w* ]]; then ${TESTCMD} --label=Mono.Posix --skip; else ${TESTCMD} --label=Mono.Posix --timeout=5m make -w -C mcs/class/Mono.Posix run-test; fi
${TESTCMD} --label=System.Web --timeout=30m make -w -C mcs/class/System.Web run-test
${TESTCMD} --label=System.Web.Services --timeout=5m make -w -C mcs/class/System.Web.Services run-test
${TESTCMD} --label=System.Runtime.SFS --timeout=5m make -w -C mcs/class/System.Runtime.Serialization.Formatters.Soap run-test;