Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds tests for rooms #181

Merged
merged 9 commits into from
Jul 31, 2023
Merged

Adds tests for rooms #181

merged 9 commits into from
Jul 31, 2023

Conversation

hbcarlos
Copy link
Member

No description provided.

@hbcarlos hbcarlos added enhancement New feature or request maintenance labels Jul 27, 2023
@hbcarlos hbcarlos requested a review from fcollonval July 27, 2023 13:41
@hbcarlos hbcarlos self-assigned this Jul 27, 2023
@github-actions
Copy link
Contributor

Binder 👈 Launch a Binder on branch hbcarlos/jupyter-collaboration/rtc-tests

Copy link
Member

@fcollonval fcollonval left a comment

Choose a reason for hiding this comment

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

Huge thanks 🙏 @hbcarlos

I have only cosmetic comments.
Regarding the CI, it will be good to fix the test on Windows - I don't know right away why they are failing. The only thing I figure out is that the failing step should not be named pypy and Windows but pypy or Windows 😝

tests/test_rooms.py Show resolved Hide resolved
tests/test_rooms.py Show resolved Hide resolved
tests/test_rooms.py Outdated Show resolved Hide resolved
tests/test_rooms.py Outdated Show resolved Hide resolved
tests/test_rooms.py Outdated Show resolved Hide resolved
Comment on lines +21 to +30
id = "test-id"
content = "test"
paths = {id: "test.txt"}
cm = FakeContentsManager({"content": content})
loader = FileLoader(
id,
FakeFileIDManager(paths),
cm,
poll_interval=0.1,
)
Copy link
Member

Choose a reason for hiding this comment

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

I'm wondering if this should be a fixture or a factory to avoid too many copy paste.

Fully optional - happy to merge as is.

Copy link
Member Author

Choose a reason for hiding this comment

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

I looked at it again. Even though it seems like code duplication, it is not. Each test uses a different argument, and we need to create and parameterize multiple fixtures.

Let's merge the PR, and I'll work on creating a proper set of helpers and fixtures for testing.

@fcollonval fcollonval removed the enhancement New feature or request label Jul 28, 2023
hbcarlos and others added 5 commits July 28, 2023 14:58
Co-authored-by: Frédéric Collonval <fcollonval@users.noreply.github.com>
Co-authored-by: Frédéric Collonval <fcollonval@users.noreply.github.com>
Co-authored-by: Frédéric Collonval <fcollonval@users.noreply.github.com>
Co-authored-by: Frédéric Collonval <fcollonval@users.noreply.github.com>
Co-authored-by: Frédéric Collonval <fcollonval@users.noreply.github.com>
@hbcarlos
Copy link
Member Author

Yes, I'll try to fix the Windows issue.

@hbcarlos hbcarlos merged commit 7bd86d1 into jupyterlab:main Jul 31, 2023
18 checks passed
@hbcarlos hbcarlos deleted the rtc-tests branch July 31, 2023 10:14
@fcollonval
Copy link
Member

Thanks a lot for making this one green @hbcarlos

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

Successfully merging this pull request may close these issues.

2 participants