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

Automatically set SHM for selenium container, and allow SHM size to be configured #1751

Merged
merged 6 commits into from
Oct 4, 2019

Conversation

glefloch
Copy link
Contributor

close #1670 by setting the shared memory to 2Go.

Copy link
Member

@bsideup bsideup left a comment

Choose a reason for hiding this comment

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

Could you please add tests that verify both behaviors? The "mounted shm" one can simply assert the result of getContainerInfo

Copy link
Member

@rnorth rnorth left a comment

Choose a reason for hiding this comment

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

Thanks @glefloch - this looks good to me.

@bsideup, anything we've missed?

) {
webDriverContainer.start();
assertEquals("Shared memory size is configured", 512 * FileUtils.ONE_MB, webDriverContainer.getShmSize());
assertEquals("No mounts present", webDriverContainer.getContainerInfo().getMounts().size(), 0);
Copy link
Member

Choose a reason for hiding this comment

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

please check that there are no shm mounts, not just any, so that if we add some volumes in future, it won't break the test (same in createContainerWithShmVolume)

Copy link
Member

Choose a reason for hiding this comment

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

FTR this one was only partially resolved. @glefloch please do not resolve other's comments, let the author resolve it when he thinks it is so

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sorry @bsideup, I will open another pull request with this fix. I thought it was only for this test...

Copy link
Member

Choose a reason for hiding this comment

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

no worries, @rnorth is working on it in #1948

@bsideup
Copy link
Member

bsideup commented Sep 24, 2019

@rnorth I left a couple of comments about the tests, good to go once fixed :)

@rnorth rnorth self-assigned this Oct 3, 2019
@rnorth rnorth dismissed bsideup’s stale review October 3, 2019 16:54

Comments look to be addressed

@rnorth rnorth changed the title Set SHM size for selenium container Automatically set SHM for selenium container, and allow SHM size to be configured Oct 4, 2019
@rnorth rnorth merged commit 5aa389a into testcontainers:master Oct 4, 2019
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.

Selenium shared memory defaults
3 participants