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

Test: Validate domain config test for attrValidator #5699

Merged
merged 2 commits into from
Mar 12, 2024

Conversation

abhishekj720
Copy link
Contributor

Description: This PR introduces enhanced unit tests for attrValidator.go in the uber/cadence/common/domain package, focusing on increasing test coverage through comprehensive, table-driven tests. It covers a range of scenarios including edge cases and error conditions for domain attribute validation functions.

Why?: To improve code quality and reliability by ensuring all logical paths are tested, which helps in early detection of potential bugs and maintains high standards for the Cadence codebase.

How did you test it?: Tests were added and executed locally to verify their effectiveness. The coverage tool was used to ensure that the new tests significantly increase coverage for attrValidator.go.

Potential risks: Minimal to none, as the changes are confined to unit tests which do not affect production code directly.

Release notes: Not applicable as the changes do not impact the functionality or schema.

@coveralls
Copy link

coveralls commented Mar 2, 2024

Pull Request Test Coverage Report for Build 018e3408-9ca1-4c65-b0c5-f0ae52900de0

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 64 unchanged lines in 14 files lost coverage.
  • Overall coverage increased (+0.008%) to 64.874%

Files with Coverage Reduction New Missed Lines %
service/history/queue/timer_queue_processor_base.go 1 77.62%
service/history/task/transfer_standby_task_executor.go 2 87.01%
common/task/weighted_round_robin_task_scheduler.go 2 88.56%
common/task/fifo_task_scheduler.go 2 85.57%
common/persistence/sql/sqlplugin/mysql/task.go 2 73.68%
common/persistence/executionManager.go 2 78.59%
common/persistence/sql/sqlplugin/mysql/db.go 2 79.49%
common/persistence/historyManager.go 2 66.67%
service/matching/taskListManager.go 3 80.2%
service/history/task/fetcher.go 4 86.08%
Totals Coverage Status
Change from base Build 018e33d9-84be-46ef-95eb-a874b895d173: 0.008%
Covered Lines: 94580
Relevant Lines: 145791

💛 - Coveralls

@abhishekj720 abhishekj720 enabled auto-merge (squash) March 12, 2024 19:00
@abhishekj720 abhishekj720 merged commit c6a10dc into cadence-workflow:master Mar 12, 2024
18 checks passed
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.

4 participants