uber / cadence

Cadence is a distributed, scalable, durable, and highly available orchestration engine to execute asynchronous long-running business logic in a scalable and resilient way.
https://cadenceworkflow.io
MIT License
7.96k stars 772 forks source link

Add Unit tests for Frontend API Handler #6122

Closed timl3136 closed 3 weeks ago

timl3136 commented 3 weeks ago

What changed? Add unit tests for RespondDecisionTaskFailed and RespondQueryTaskCompleted methods in frontend api handler

Why? Improve test coverage

How did you test it? Unit tests

Potential risks

Release notes

Documentation Changes

codecov[bot] commented 3 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 72.01%. Comparing base (b3e21fa) to head (e57054d).

Additional details and impacted files [see 10 files with indirect coverage changes](https://app.codecov.io/gh/uber/cadence/pull/6122/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=uber) ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/uber/cadence/pull/6122?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=uber). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=uber) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/uber/cadence/pull/6122?dropdown=coverage&src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=uber). Last update [b3e21fa...e57054d](https://app.codecov.io/gh/uber/cadence/pull/6122?dropdown=coverage&src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=uber). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=uber).
coveralls commented 3 weeks ago

Pull Request Test Coverage Report for Build 018fef2a-cf8f-43ca-8b6d-218108c1f3d4

Details


Files with Coverage Reduction New Missed Lines %
service/history/task/timer_task_executor_base.go 2 80.21%
common/cache/lru.go 2 93.01%
service/matching/tasklist/task_list_manager.go 2 76.65%
common/task/fifo_task_scheduler.go 2 85.57%
service/frontend/api/handler.go 2 73.55%
service/history/replication/task_processor.go 2 82.76%
service/matching/tasklist/task_reader.go 2 76.66%
service/history/task/transfer_standby_task_executor.go 3 86.73%
service/history/task/task.go 3 84.81%
service/history/queue/timer_queue_processor_base.go 3 77.87%
<!-- Total: 41 -->
Totals Coverage Status
Change from base Build 018feeec-d7a4-4bb0-b278-1977f0e4c7ed: 0.05%
Covered Lines: 106330
Relevant Lines: 148957

💛 - Coveralls