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

Integrate testcontainers #366

Merged
merged 2 commits into from
Jun 15, 2023

Conversation

LotharSpiegel
Copy link

Proposition to resolve #261 (missing test setup) by using the testcontainers Java library. The proposed solution spins up a WebDAV server inside a Docker container during tests. By using this approach, the test setup becomes independent from external resources, as opposed to using a publicly hosted WebDAV server.

@dkocher
Copy link
Collaborator

dkocher commented Apr 18, 2023

It should then be possible to no longer exclude the tests marked with @IntegrationTest 1.

Footnotes

  1. https://github.com/lookfirst/sardine/blob/master/pom.xml#L107

@dkocher
Copy link
Collaborator

dkocher commented Apr 19, 2023

It should then be possible to no longer exclude the tests marked with @IntegrationTest 1.

Footnotes

  1. https://github.com/lookfirst/sardine/blob/master/pom.xml#L107

@lookfirst Probably we should keep as is and run only unit tests in the surefire plugin?

@dkocher dkocher requested a review from lookfirst April 19, 2023 10:55
@lookfirst
Copy link
Owner

It should then be possible to no longer exclude the tests marked with @IntegrationTest 1.

Footnotes

  1. https://github.com/lookfirst/sardine/blob/master/pom.xml#L107

@lookfirst Probably we should keep as is and run only unit tests in the surefire plugin?

I love this PR. Sounds good to only run unit tests in maven and then run integration tests in this PR.

nicolasb29 added a commit to nicolasb29/sardine that referenced this pull request May 8, 2023
@LotharSpiegel
Copy link
Author

It should then be possible to no longer exclude the tests marked with @IntegrationTest 1.

Footnotes

  1. https://github.com/lookfirst/sardine/blob/master/pom.xml#L107

@lookfirst Probably we should keep as is and run only unit tests in the surefire plugin?

I love this PR. Sounds good to only run unit tests in maven and then run integration tests in this PR.

Thank you for reviewing! So do you mean to leave the exclusion of integration tests as is in the maven-surefire-plugin? If I understand correctly, the integration tests are then executed in the maven-failsafe-plugin.

@dkocher
Copy link
Collaborator

dkocher commented May 14, 2023

I suggest to just run integration tests as is with the maven-failsafe-plugin but enable by default 1.

Footnotes

  1. https://github.com/lookfirst/sardine/blob/8b5d445d8a25b13c31b70773d26b8e3442b0e0e7/pom.xml#L176-L177

@dkocher dkocher merged commit cc86502 into lookfirst:master Jun 15, 2023
@dkocher
Copy link
Collaborator

dkocher commented Jun 16, 2023

@LotharSpiegel Do you have experience with testcontainers running in the context of Github Actions using Github-hosted runners? It seems there is no Docker environment available.

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.

The tests are using googlecode's WebDAV
3 participants