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 tests for service/matching/handler/handler.go #6116

Closed fimanishi closed 3 weeks ago

fimanishi commented 3 weeks ago

What changed? tests for service/matching/handler/handler.go

Why? improve unit 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 71.39%. Comparing base (dc2a3a1) to head (f01e807). Report is 25 commits behind head on master.

Additional details and impacted files [see 34 files with indirect coverage changes](https://app.codecov.io/gh/uber/cadence/pull/6116/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/6116?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/6116?dropdown=coverage&src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=uber). Last update [dc2a3a1...f01e807](https://app.codecov.io/gh/uber/cadence/pull/6116?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 018fea7a-18b7-47bd-a290-626b1503cb11

Details


Files with Coverage Reduction New Missed Lines %
common/task/weighted_round_robin_task_scheduler.go 2 88.56%
common/persistence/historyManager.go 2 66.67%
service/history/task/transfer_standby_task_executor.go 4 87.35%
bench/lib/client.go 4 0.0%
service/matching/config/config.go 4 91.49%
service/history/engine/engineimpl/start_workflow_execution.go 5 77.76%
service/history/engine/engineimpl/reset_sticky_tasklist.go 6 66.67%
service/history/engine/engineimpl/terminate_workflow_execution.go 8 80.0%
service/history/engine/engineimpl/history_engine.go 9 82.94%
common/domain/replication_queue.go 18 74.83%
<!-- Total: 466 -->
Totals Coverage Status
Change from base Build 018fea60-5d6d-4e72-9c82-d4d291808f26: -0.1%
Covered Lines: 105258
Relevant Lines: 148952

πŸ’› - Coveralls
coveralls commented 3 weeks ago

Pull Request Test Coverage Report for Build 018feab2-8717-4ed8-a03c-5959e4a21454

Details


Files with Coverage Reduction New Missed Lines %
service/history/task/transfer_active_task_executor.go 2 72.9%
service/matching/tasklist/matcher.go 2 89.35%
service/matching/tasklist/task_reader.go 2 77.72%
bench/lib/client.go 4 0.0%
common/archiver/filestore/historyArchiver.go 4 80.95%
common/types/mapper/thrift/shared.go 4 98.31%
service/matching/config/config.go 4 91.49%
service/history/engine/engineimpl/start_workflow_execution.go 5 77.76%
service/history/task/transfer_standby_task_executor.go 6 86.33%
service/history/engine/engineimpl/reset_sticky_tasklist.go 6 66.67%
<!-- Total: 977 -->
Totals Coverage Status
Change from base Build 018feaa3-8a65-4c9c-874c-0243b9141bed: -0.5%
Covered Lines: 105251
Relevant Lines: 148952

πŸ’› - Coveralls
coveralls commented 3 weeks ago

Pull Request Test Coverage Report for Build 018fee8f-064e-4387-b1d1-93c64d6eb36f

Details


Files with Coverage Reduction New Missed Lines %
service/history/queue/timer_queue_processor_base.go 1 77.66%
common/persistence/sql/sqlplugin/postgres/task.go 2 73.4%
service/history/task/transfer_standby_task_executor.go 3 86.33%
service/history/task/task.go 3 84.81%
bench/lib/client.go 4 0.0%
common/types/mapper/thrift/shared.go 4 98.31%
service/matching/config/config.go 4 91.49%
service/history/engine/engineimpl/start_workflow_execution.go 5 77.76%
service/history/engine/engineimpl/reset_sticky_tasklist.go 6 66.67%
service/history/execution/cache.go 6 74.61%
<!-- Total: 1172 -->
Totals Coverage Status
Change from base Build 018fee53-2f0a-42d7-9d39-e20b5cb03809: -0.6%
Covered Lines: 105262
Relevant Lines: 148952

πŸ’› - Coveralls