Skip to content

Commit

Permalink
[Mono.Android-Tests] Fix repo URL in redirect tests (#9035)
Browse files Browse the repository at this point in the history
A handful of tests started failing after the org move:

    Xamarin.Android.NetTests.AndroidHandlerTestBase.Redirect_POST_With_Content_Works
        Invalid redirected URI
        Expected: https://github.com/xamarin/xamarin-android
        But was:  https://github.com/dotnet/android

Fix these by using the new repo URL.
  • Loading branch information
pjcollins authored Jun 14, 2024
1 parent 40f07f5 commit 75e5599
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,8 @@ public void Property_Timeout_Works()
[Test]
public void Redirect_Without_Protocol_Works()
{
var requestURI = new Uri ("https://httpbin.org/redirect-to?url=https://github.com/xamarin/xamarin-android");
var redirectedURI = new Uri ("https://github.com/xamarin/xamarin-android");
var requestURI = new Uri ("https://httpbin.org/redirect-to?url=https://github.com/dotnet/android");
var redirectedURI = new Uri ("https://github.com/dotnet/android");
using (var c = new HttpClient (CreateHandler ())) {
var tr = ConnectIgnoreFailure (() => c.GetAsync (requestURI), out bool connectionFailed);
if (connectionFailed)
Expand All @@ -267,8 +267,8 @@ public void Redirect_Without_Protocol_Works()
[Test]
public void Redirect_POST_With_Content_Works ()
{
var requestURI = new Uri ("https://httpbin.org/redirect-to?url=https://github.com/xamarin/xamarin-android");
var redirectedURI = new Uri ("https://github.com/xamarin/xamarin-android");
var requestURI = new Uri ("https://httpbin.org/redirect-to?url=https://github.com/dotnet/android");
var redirectedURI = new Uri ("https://github.com/dotnet/android");
using (var c = new HttpClient (CreateHandler ())) {
var request = new HttpRequestMessage (HttpMethod.Post, requestURI);
request.Content = new StringContent("{}", Encoding.UTF8, "application/json");
Expand Down

0 comments on commit 75e5599

Please sign in to comment.