Skip to content

Consolidate locking dependencies into LockContext - #43

Merged
benrowe merged 2 commits into
masterfrom
feature/issue-25-consolidate-locking-dependencies
Dec 12, 2025
Merged

benrowe merged 2 commits into
masterfrom
feature/issue-25-consolidate-locking-dependencies

Conversation

@benrowe

@benrowe benrowe commented Dec 12, 2025

Copy link
Copy Markdown
Collaborator

Summary

  • Created new LockContext class to bundle all locking dependencies
  • Updated StateFlow constructor to accept single nullable LockContext instead of three separate nullable parameters
  • Updated all test files to use new LockContext API

Benefits

  • ✅ Single nullable dependency for locking
  • ✅ Impossible to provide partial locking configuration
  • ✅ Cleaner API for users
  • ✅ All locking concerns in one place
  • ✅ Easier to test (one mock vs three)

Breaking Change

This is a breaking change to StateFlow constructor signature. Since project is alpha, no migration path needed.

Closes #25

Test plan

  • All existing tests pass (367 tests, 1244 assertions)
  • 100% code coverage maintained
  • All quality checks pass (lint, PHPStan, PHPMD)
  • New unit tests for LockContext class

🤖 Generated with Claude Code

benrowe and others added 2 commits December 13, 2025 08:33
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@benrowe
benrowe merged commit e4be637 into master Dec 12, 2025
8 checks passed
@benrowe
benrowe deleted the feature/issue-25-consolidate-locking-dependencies branch December 12, 2025 21:41
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.

Consolidate locking dependencies into LockContext

1 participant