4paradigm / 4paradigm/OpenMLDB
feat(tools): refactor the use of `steps/ut.sh`
- Ngôn ngữ chính
- C++
- Star
- 1.7k
- Fork
- 331
- Merge trung bình
- 12 ngày 12 giờ
- Pull request đã merge (30 ngày)
- 1
Mô tả
**Is your feature request related to a problem? Please describe.**
#940
**Describe the solution you'd like**
The `steps/ut.sh` was used to run both unit test and integration test, it also start zookeeper at beginning and stop in the end.
But script is not stable and, not play well with coverage task, the cpp coverage test only pick tests that were added by `add_test` in CMakeLists.txt.
So the solution might be:
- [x] add unit tests with `add_test` in CMakeLists.txt, so they will be picked up directly by `make test`
- [ ] `steps/ut.sh` will use to run integration test only, and will setup zookeeper if not available. rename the script name
- [ ] unite start/stop zookeeper in one place, do not maintain different zookeeper up/down in different place. It might resolved in a standalone issue
Hướng dẫn đóng góp
Hướng nghiên cứu
Look at the `steps/ut.sh` script and the CMakeLists.txt files to understand the current test structure. The goal is to separate unit tests (added via `add_test`) from integration tests. Check how zookeeper is started/stopped in different places and plan to consolidate it. Run `make test` to see which tests are currently picked up.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- cmake, cpp, shell
- Lĩnh vực
- build-system, testing-qa, tooling
- Loại issue
- Tái cấu trúc
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 45/100