The following comments were left on PR #2551 by @olleolleolle:
Comment 1: Test organization
olleolleolle Apr 9, 2026
Ergonomics: I assume it'd be possible to have a `describe "handling deduplication"` block, wrapping these test cases, and placing them in a spec/models/invitation_manager_spec.rb, so that "flipping between test and implementation" works in an expected way.
Suggested action: Move the deduplication tests from `spec/models/invitation_manager_deduplication_spec.rb` into `spec/models/invitation_manager_spec.rb` under a `describe "handling deduplication"` block.
Comment 2: Use `described_class` instead of hardcoded class name
olleolleolle Apr 9, 2026
Suggested change:
```ruby
subject(:manager) { InvitationManager.new }
```
to:
```ruby
subject(:manager) { described_class.new }
```
Very minor in this test file, but in other cases, when it's repeated a lot in a test, it makes renaming classes more cumbersome.
Suggested action: Update the test file to use `described_class.new` instead of `InvitationManager.new`.
The following comments were left on PR #2551 by @olleolleolle:
Comment 1: Test organization
Suggested action: Move the deduplication tests from `spec/models/invitation_manager_deduplication_spec.rb` into `spec/models/invitation_manager_spec.rb` under a `describe "handling deduplication"` block.
Comment 2: Use `described_class` instead of hardcoded class name
Suggested action: Update the test file to use `described_class.new` instead of `InvitationManager.new`.