From eda0f3f24851d028a8da56216e1259d01fbfde26 Mon Sep 17 00:00:00 2001 From: Travis Ralston Date: Mon, 18 Nov 2024 14:14:17 -0700 Subject: [PATCH] Fix tests --- test/upload_suite_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/upload_suite_test.go b/test/upload_suite_test.go index b203b8ce..042c2d85 100644 --- a/test/upload_suite_test.go +++ b/test/upload_suite_test.go @@ -62,7 +62,7 @@ func (s *UploadTestSuite) TestUpload() { assert.Equal(t, client1.ServerName, origin) assert.NotEmpty(t, mediaId) - raw, err := client2.DoRaw("GET", fmt.Sprintf("/_matrix/media/v3/download/%s/%s", origin, mediaId), nil, "", nil) + raw, err := client2.DoRaw("GET", fmt.Sprintf("/_matrix/client/v1/media/download/%s/%s", origin, mediaId), nil, "", nil) assert.NoError(t, err) assert.Equal(t, raw.StatusCode, http.StatusOK) test_internals.AssertIsTestImage(t, raw.Body) @@ -278,7 +278,7 @@ func (s *UploadTestSuite) TestUploadAsyncFlow() { assert.NotEmpty(t, mediaId) // Do a test download to ensure that the media doesn't (yet) exist - errRes, err := client2.DoExpectError("GET", fmt.Sprintf("/_matrix/media/v3/download/%s/%s", origin, mediaId), url.Values{ + errRes, err := client2.DoExpectError("GET", fmt.Sprintf("/_matrix/client/v1/media/download/%s/%s", origin, mediaId), url.Values{ "timeout_ms": []string{"1000"}, }, "", nil) assert.NoError(t, err) @@ -303,7 +303,7 @@ func (s *UploadTestSuite) TestUploadAsyncFlow() { assert.Equal(t, http.StatusConflict, errRes.InjectedStatusCode) // Download and test the upload - raw, err := client2.DoRaw("GET", fmt.Sprintf("/_matrix/media/v3/download/%s/%s", origin, mediaId), nil, "", nil) + raw, err := client2.DoRaw("GET", fmt.Sprintf("/_matrix/client/v1/media/download/%s/%s", origin, mediaId), nil, "", nil) assert.NoError(t, err) assert.Equal(t, raw.StatusCode, http.StatusOK) test_internals.AssertIsTestImage(t, raw.Body)