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

feat: Integrate testcontainers into the current test environment #2524

Open
wants to merge 26 commits into
base: 2021.x
Choose a base branch
from

Conversation

kaori-seasons
Copy link
Collaborator

@kaori-seasons kaori-seasons commented May 2, 2022

Describe what this PR does / why we need it

related to integrated test environment
improve pospal

It is necessary to design a set of integration testing solutions for the project, which can better test whether the functions of components such as Nacos, RocketMQ, Seata, Sentinel in the project serve expectations, improve the efficiency of project integration testing, and realize intelligent automatic testing through Github CI

Code branch: integration-test

Project background: Previously in the spring-cloud-alibaba-tests/nacos-old-tests module, based on the @HasDockerAndItEnabled annotation
Execute mvn clean -Dit.enabled=true test in the ci script to execute all unit tests marked with this annotation

Currently we need to plug in our new version of unit tests for nacos and rocketmq whenever a new module needs to be plugged in
Specify the module in spring-cloud-alibaba-tests/spring-cloud-alibaba-testcontainers/pom.xml
The following work needs to be done

  1. In the new module spring-cloud-alibaba-tests/intergration/nacos-docker-tests
    To do some nacos coverage tests, you can refer to the unit tests of each module of nacos
    File path: https://github.com/alibaba/nacos/tree/develop/test
    Improve the test coverage of the nacos module

  2. In the new module spring-cloud-alibaba-tests/intergration/rocketmq-docker-tests
    Do some coverage tests of rocketmq, you can refer to rocketmq
    File path: https://github.com/apache/rocketmq/tree/develop/test/src/test

  3. For the actual use of the user, the mixed use of nacos + rocketmq may occur.

Currently some actions can be predefined in the xxxxTester class
Path: spring-cloud-alibaba-tests/spring-cloud-alibaba-testcontainers/src/main/java/com/alibaba/cloud/integration/common

You can try to start by combining containers to improve coverage
It is expected to do e2e end-to-end testing similar to the following KafkaDebeziumSourceTests
File path: apache/flink@master...complone:flink-hackthon-2021-issue-6

  1. If you have spare capacity, you can explore to improve the test coverage in other directions, such as sentinel, seata

Does this pull request fix one issue?

Describe how you did it

Describe how to verify it

Special notes for reviews

@kaori-seasons kaori-seasons marked this pull request as draft May 2, 2022 09:02
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.

1 participant