Skip to content

Conversation

@abtreece
Copy link
Owner

@abtreece abtreece commented Jan 6, 2026

Summary

  • Refactored Redis client to use redisConn interface for mocking

  • Added comprehensive Redis GetValues tests covering string, hash, and scan patterns

  • Added Redis WatchPrefix and connectedClient tests

  • Redis coverage improved from 6.9% to 51.0%

  • Refactored Etcd client to use etcdKV interface for mocking

  • Added comprehensive Etcd GetValues tests with mock transactions

  • Etcd coverage improved from 12.1% to 37.9%

Overall project coverage improved from 40.2% to 44.9%

Test plan

  • All existing tests pass
  • New Redis tests pass with -vet=off (existing vet warnings in code)
  • New Etcd tests pass
  • Coverage verified with go test -coverprofile

🤖 Generated with Claude Code

- Refactor Redis client to use redisConn interface for mocking
- Add comprehensive Redis GetValues tests (string, hash, scan patterns)
- Add Redis WatchPrefix and connectedClient tests
- Coverage improved from 6.9% to 51.0% for Redis

- Refactor Etcd client to use etcdKV interface for mocking
- Add comprehensive Etcd GetValues tests with mock transactions
- Coverage improved from 12.1% to 37.9% for Etcd

Overall coverage improved from 40.2% to 44.9%

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@abtreece abtreece merged commit f7cc958 into main Jan 6, 2026
6 checks passed
@abtreece abtreece deleted the feat/improve-redis-etcd-coverage branch January 6, 2026 22:54
@codecov
Copy link

codecov bot commented Jan 6, 2026

Codecov Report

❌ Patch coverage is 66.66667% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 39.85%. Comparing base (da3cdb4) to head (483eace).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
pkg/backends/etcd/client.go 50.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #320      +/-   ##
==========================================
+ Coverage   34.34%   39.85%   +5.50%     
==========================================
  Files          19       19              
  Lines        1706     1706              
==========================================
+ Hits          586      680      +94     
+ Misses       1061      955     -106     
- Partials       59       71      +12     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

1 participant