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

chore(POC): integration tests #208

Merged
merged 11 commits into from
Oct 17, 2023

Conversation

guicamest
Copy link
Contributor

@guicamest guicamest commented Oct 5, 2023

Related to Discussion #181

Description of changes:
Following the discussion, some simple integration tests have been added to the project. The tests are located in a new source set integrationTest and can be executed by running ./gradlew integrationTest. The only requirement to run them is docker.

The tests treat the library as black box, in order to ensure that the way users should use the library works as expected (i.e. use Files and Paths api. Localstack is used as a temporary "S3" server, given it's simplicity to setup, speed and parity with S3 features.

Gradle wrapper has been updated from 7.1 to 7.3.3 which introduced the offical jvm-test-suite plugin. This reduces the amount of configuration needed to setup integration tests in the build, as well as reuse dependencies between tests.

The aggregation of coverage reports (test + integrationTest) is not part of this PR as there might be changes on this PR. It should require another update of Gradle (to 7.4.2) and a bit of configuration.

Some links used while developing:
Localstack S3 User Guide
Localstack 2.3 release
Testcontainers Junit 5 integration
Testcontainers Localstack integration
Testcontainers configuration
Modern Best Practices for Testing

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Copy link
Contributor

@markjschreiber markjschreiber left a comment

Choose a reason for hiding this comment

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

Looks great! Thanks for the contribution

@markjschreiber markjschreiber merged commit 6726734 into awslabs:main Oct 17, 2023
1 check passed
@guicamest
Copy link
Contributor Author

Glad that you liked it! 🎉

@guicamest guicamest deleted the pocIntegrationTests branch October 19, 2023 08:37
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