Skip to content

Start adding tests for MSC4140#734

Merged
anoadragon453 merged 17 commits into
matrix-org:mainfrom
AndrewFerr:af/msc4140
Sep 18, 2024
Merged

Start adding tests for MSC4140#734
anoadragon453 merged 17 commits into
matrix-org:mainfrom
AndrewFerr:af/msc4140

Conversation

@AndrewFerr
Copy link
Copy Markdown
Member

Signed-off-by: Andrew Ferrazzutti andrewf@element.io

Pull Request Checklist

AndrewFerr added a commit to AndrewFerr/synapse that referenced this pull request Sep 16, 2024
@AndrewFerr AndrewFerr marked this pull request as ready for review September 16, 2024 20:29
@AndrewFerr AndrewFerr requested review from a team as code owners September 16, 2024 20:29
Copy link
Copy Markdown
Member

@anoadragon453 anoadragon453 left a comment

Choose a reason for hiding this comment

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

Great work so far! Tests are clear and easy to read.

Comment thread tests/msc4140/delayed_event_test.go Outdated
Comment on lines +151 to +153
deployment.StopServer(t, hsName)
time.Sleep(1 * time.Second)
deployment.StartServer(t, hsName)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I worry that Synapse may not always start in 10s, especially when running with a ton of workers. See the list of workers we run in the Synapse repo's Complement CI.

Unfortunately it doesn't look like we're testing with Synapse workers in Complement's CI. Have you tried running with workers locally? Otherwise, perhaps we can just merge these tests and see how they do on the Synapse PR's CI?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I've done some light local testing with workers, though not in Complement runs.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Let's merge it and see, I suppose. We can always bump this timeout as a quick fix before converting it to a unit test, if necessary.

Comment thread tests/msc4140/delayed_event_test.go
Comment thread tests/msc4140/delayed_event_test.go
Comment thread tests/msc4140/delayed_event_test.go
Copy link
Copy Markdown
Member

@anoadragon453 anoadragon453 left a comment

Choose a reason for hiding this comment

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

This LGTM! Thanks for addressing the changes.

Comment thread tests/msc4140/delayed_event_test.go
Comment on lines +151 to +153
deployment.StopServer(t, hsName)
time.Sleep(1 * time.Second)
deployment.StartServer(t, hsName)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Let's merge it and see, I suppose. We can always bump this timeout as a quick fix before converting it to a unit test, if necessary.

Comment thread tests/msc4140/delayed_event_test.go
@anoadragon453 anoadragon453 merged commit b0bc680 into matrix-org:main Sep 18, 2024
@AndrewFerr AndrewFerr deleted the af/msc4140 branch September 18, 2024 19:09
@anoadragon453 anoadragon453 mentioned this pull request Sep 23, 2024
1 task
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.

2 participants