Skip to content

TestAsyncUpload: download with authentication#746

Merged
reivilibre merged 1 commit into
mainfrom
rei/async_upload_auth_media
Nov 20, 2024
Merged

TestAsyncUpload: download with authentication#746
reivilibre merged 1 commit into
mainfrom
rei/async_upload_auth_media

Conversation

@reivilibre
Copy link
Copy Markdown
Contributor

This fixes support with homeservers that enforce authenticated media, such as Synapse in element-hq/synapse#17889

Pull Request Checklist

Signed-off-by: Olivier 'reivilibre' oliverw@element.io

This fixes support with homeservers that enforce authenticated media,
such as Synapse in element-hq/synapse#17889
@reivilibre reivilibre requested review from a team as code owners November 18, 2024 16:59
@reivilibre reivilibre merged commit fde26d9 into main Nov 20, 2024
@reivilibre reivilibre deleted the rei/async_upload_auth_media branch November 20, 2024 14:06

t.Run("Download media", func(t *testing.T) {
content, contentType := alice.DownloadContent(t, mxcURI)
content, contentType := alice.DownloadContentAuthenticated(t, mxcURI)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is already a test below that does authenticated media download (see DownloadContentAuthenticated(...) usage below.

Now we just have two of the same test.

Is there a way we can ask the homeserver whether unauthenticated media is supported and gate the test that way?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants