Skip to content

Commit

Permalink
Disable more tests dependent on http://corefx-net-http11.azurewebsite…
Browse files Browse the repository at this point in the history
…s.net (dotnet#111354)

* Disable more tests dependent on http://corefx-net-http11.azurewebsites.net

* Disable winhttphandlertests
  • Loading branch information
rzikm committed Jan 14, 2025
1 parent 9623ff9 commit b745aba
Show file tree
Hide file tree
Showing 2 changed files with 82 additions and 7 deletions.
53 changes: 48 additions & 5 deletions src/libraries/Common/tests/System/Net/Configuration.Http.cs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,22 @@ public static partial class Http
public static readonly Uri RemoteEchoServer = new Uri("http://" + Host + "/" + EchoHandler);
public static readonly Uri SecureRemoteEchoServer = new Uri("https://" + SecureHost + "/" + EchoHandler);
public static readonly Uri Http2RemoteEchoServer = new Uri("https://" + Http2Host + "/" + EchoHandler);
public static readonly Uri[] EchoServerList = new Uri[] { RemoteEchoServer, SecureRemoteEchoServer, Http2RemoteEchoServer };
public static Uri[] GetEchoServerList()
{
if (PlatformDetection.IsFirefox)
{
// https://github.com/dotnet/runtime/issues/101115
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// return [RemoteEchoServer];
return [];
}
return [
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// RemoteEchoServer,
SecureRemoteEchoServer,
Http2RemoteEchoServer
];
}

public static readonly Uri RemoteVerifyUploadServer = new Uri("http://" + Host + "/" + VerifyUploadHandler);
public static readonly Uri SecureRemoteVerifyUploadServer = new Uri("https://" + SecureHost + "/" + VerifyUploadHandler);
Expand All @@ -72,9 +87,21 @@ public static partial class Http
public static readonly Uri Http2RemoteGZipServer = new Uri("https://" + Http2Host + "/" + GZipHandler);
public static Uri RemoteLoopServer => new Uri("ws://" + RemoteLoopHost + "/" + RemoteLoopHandler);

public static readonly object[][] EchoServers = EchoServerList.Select(x => new object[] { x }).ToArray();
public static readonly object[][] VerifyUploadServers = { new object[] { RemoteVerifyUploadServer }, new object[] { SecureRemoteVerifyUploadServer }, new object[] { Http2RemoteVerifyUploadServer } };
public static readonly object[][] CompressedServers = { new object[] { RemoteDeflateServer }, new object[] { RemoteGZipServer }, new object[] { Http2RemoteDeflateServer }, new object[] { Http2RemoteGZipServer } };
public static readonly object[][] EchoServers = GetEchoServerList().Select(x => new object[] { x }).ToArray();
public static readonly object[][] VerifyUploadServers = {
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// new object[] { RemoteVerifyUploadServer },
new object[] { SecureRemoteVerifyUploadServer },
new object[] { Http2RemoteVerifyUploadServer }
};

public static readonly object[][] CompressedServers = {
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// new object[] { RemoteDeflateServer },
new object[] { RemoteGZipServer },
new object[] { Http2RemoteDeflateServer },
new object[] { Http2RemoteGZipServer }
};

public static readonly object[][] Http2Servers = { new object[] { new Uri("https://" + Http2Host) } };
public static readonly object[][] Http2NoPushServers = { new object[] { new Uri("https://" + Http2NoPushHost) } };
Expand All @@ -83,7 +110,23 @@ public static partial class Http
public static readonly RemoteServer RemoteSecureHttp11Server = new RemoteServer(new Uri("https://" + SecureHost + "/"), HttpVersion.Version11);
public static readonly RemoteServer RemoteHttp2Server = new RemoteServer(new Uri("https://" + Http2Host + "/"), new Version(2, 0));

public static readonly IEnumerable<RemoteServer> RemoteServers = new RemoteServer[] { RemoteHttp11Server, RemoteSecureHttp11Server, RemoteHttp2Server };
public static IEnumerable<RemoteServer> GetRemoteServers()
{
if (PlatformDetection.IsFirefox)
{
// https://github.com/dotnet/runtime/issues/101115
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// return new RemoteServer[] { RemoteHttp11Server };
return [];
}
return new RemoteServer[]
{
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// RemoteHttp11Server,
RemoteSecureHttp11Server,
RemoteHttp2Server
};
}

public static readonly IEnumerable<object[]> RemoteServersMemberData = RemoteServers.Select(s => new object[] { s });

Expand Down
36 changes: 34 additions & 2 deletions src/libraries/Common/tests/System/Net/Configuration.WebSockets.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,40 @@ public static partial class WebSockets
public static readonly Uri RemoteEchoHeadersServer = new Uri("ws://" + Host + "/" + EchoHeadersHandler);
public static readonly Uri SecureRemoteEchoHeadersServer = new Uri("wss://" + SecureHost + "/" + EchoHeadersHandler);

public static readonly object[][] EchoServers = { new object[] { RemoteEchoServer }, new object[] { SecureRemoteEchoServer } };
public static readonly object[][] EchoHeadersServers = { new object[] { RemoteEchoHeadersServer }, new object[] { SecureRemoteEchoHeadersServer } };
public static object[][] GetEchoServers()
{
if (PlatformDetection.IsFirefox)
{
// https://github.com/dotnet/runtime/issues/101115
return new object[][] {
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// new object[] { RemoteEchoServer },

};
}
return new object[][] {
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// new object[] { RemoteEchoServer },
new object[] { SecureRemoteEchoServer },
};
}

public static object[][] GetEchoHeadersServers()
{
if (PlatformDetection.IsFirefox)
{
// https://github.com/dotnet/runtime/issues/101115
return new object[][] {
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// new object[] { RemoteEchoHeadersServer },
};
}
return new object[][] {
// [ActiveIssue("https://github.com/dotnet/runtime/issues/110578)]
// new object[] { RemoteEchoHeadersServer },
new object[] { SecureRemoteEchoHeadersServer },
};
}
}
}
}

0 comments on commit b745aba

Please sign in to comment.