Implement unit test #47

Merged
stanislav.hejny merged 11 commits from unittest-coverage-85 into develop 2025-05-19 14:30:16 +00:00
Member

This PR implements the unit test and ensures the coverage is above 85%, with help from cursor to generate most of the unit test.

This PR implements the unit test and ensures the coverage is above 85%, with help from cursor to generate most of the unit test.
feat \#16 - add unittest for backpressure_handler and logging_utils
Some checks failed
Unit test coverage / pytest (push) Failing after 3h11m10s
bc98351493
test(General): write test for pydantic serializer, fixed serialization bug
Some checks failed
Unit test coverage / pytest (push) Failing after 3h11m8s
45357c42a8
This commit write unit tests for pydantic serializer using cursor ai, and found an issue related to serialization. Originally, the code uses comma to concat string, but map and list also has comma inside. During the deserialization, split using comma will break map and list, leaving `{` with first kv pair for map, and `[` with first element with list. Instead of using concat with comma as separator, I use json to encode the object dict.
Partially finished the unit test for file handler
Some checks failed
Unit test coverage / pytest (push) Failing after 3h4m2s
98fc52fc26
issue #16 - fix the pytest hanging after test main thread exits
Some checks failed
Unit test coverage / pytest (push) Failing after 1m4s
53dce69e8f
test(General): fix existing unit tests for cleverthis service adapter
Some checks failed
Unit test coverage / pytest (push) Failing after 1m10s
883ea3400f
Should bump coverage rate to 62%
test(General): implement unit test for data parser, rabbitmq client and other python files
Some checks failed
Unit test coverage / pytest (push) Failing after 1m7s
aec53f5b34
This commit bump the coverage rate to 77%
test(General): finished unit test, coverage 88%
All checks were successful
Unit test coverage / pytest (push) Successful in 1m8s
Unit test coverage / pytest (pull_request) Successful in 1m6s
2e12d5ab57
ISSUES CLOSED: clevermicro/amq-adapter-python#16
requested reviews from abed.alrahman, stanislav.hejny 2025-05-16 10:20:03 +00:00

Coverage is 88%

Coverage is 88%
feat #16 - update version so the code can be published as artifact
All checks were successful
Unit test coverage / pytest (push) Successful in 1m19s
Unit test coverage / pytest (pull_request) Successful in 1m17s
3e0f769837

Coverage is 86%

Coverage is 86%
hurui200320 deleted branch unittest-coverage-85 2025-05-20 06:50:17 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Blocks
#16 Ensure UnitTest coverage at least 85%
clevermicro/amq-adapter-python
Reference: clevermicro/amq-adapter-python#47
No description provided.