Skip to content

[Unit Tests] LocaleSettingChain, BleedManager, and McRPGDisplayDecimalFormatter coverage#240

Open
DiamondDagger590 wants to merge 2 commits into
recodefrom
claude/brave-goldberg-5MElL
Open

[Unit Tests] LocaleSettingChain, BleedManager, and McRPGDisplayDecimalFormatter coverage#240
DiamondDagger590 wants to merge 2 commits into
recodefrom
claude/brave-goldberg-5MElL

Conversation

@DiamondDagger590

Copy link
Copy Markdown
Owner

Summary

  • LocaleSettingChain (0% → 100%): 14 tests covering circular chain building with no specific locales, with single/multiple specific locales, alphabetical ordering, node lookup for CLIENT_LOCALE/SERVER_LOCALE/SpecificLocaleSetting, getNextSettingNode navigation, circular wrap-around, unknown locale fallback to head, and blank locale code filtering
  • BleedManager (0% → 100%): 28 tests covering state queries (isEntityBleeding, isEntityBleedImmune, canEntityStartBleeding) for both UUID and LivingEntity overloads, state mutations (stopEntityBleeding, endEntityBleedImmunity), startBleeding guards (already bleeding, bleed immune), all startBleeding overloads (config-based, explicit params, with/without AbilityHolder), immunity expiration via MockBukkit scheduler tick advancement, and full lifecycle integration (bleed→stop→restart, immunity→end→bleed)
  • McRPGDisplayDecimalFormatter (35% → 100%): 12 new tests covering McRPGPlayer overloads with locale chain head resolution (double, float, custom digit bounds), Audience overloads for Player with loaded McRPGPlayer (uses player locale), Player with unloaded McRPGPlayer (falls back to server default), non-Player Audience (uses server default), and all no-manager-throws paths for every McRPGPlayer/Audience overload variant (double, float, custom digits)

Classes covered

Class Before After Tests added
LocaleSettingChain 0% 100% 14
BleedManager 0% 100% 28
McRPGDisplayDecimalFormatter 35% 100% 12

Total: 54 new test cases across 3 test files

Test plan

  • All tests pass via ./gradlew verifiedShadowJar
  • No regressions in existing test classes
  • Persona testing audit run against changes
  • BleedManager tests use MockBukkit scheduler for immunity expiration verification
  • McRPGDisplayDecimalFormatter audience tests use Mockito (no MockBukkit needed — pure formatting logic)

https://claude.ai/code/session_013g1ovt1fojJgK2y5hJxzGM


Generated by Claude Code

…DecimalFormatter

- LocaleSettingChain (0% → 100%): 14 tests covering chain building,
  node lookup, circular navigation, alphabetical ordering, blank locale
  filtering, and unknown locale fallback
- BleedManager (0% → 100%): 28 tests covering state queries
  (isEntityBleeding, isEntityBleedImmune, canEntityStartBleeding),
  state mutations (stop, end immunity), startBleeding guards, immunity
  expiration via scheduler, and full lifecycle integration
- McRPGDisplayDecimalFormatter (35% → 100%): 12 new tests covering
  McRPGPlayer overloads with locale chain resolution, Audience overloads
  for loaded/unloaded players and non-Player audiences, and all
  no-manager-throws paths for every overload variant

https://claude.ai/code/session_013g1ovt1fojJgK2y5hJxzGM
@coderabbitai

coderabbitai Bot commented Jun 7, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@DiamondDagger590, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 50 minutes and 18 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: e8e4d01d-5e01-4308-9150-7527a56b836a

📥 Commits

Reviewing files that changed from the base of the PR and between 9b47c9a and 5578683.

📒 Files selected for processing (3)
  • src/test/java/us/eunoians/mcrpg/ability/impl/swords/bleed/BleedManagerTest.java
  • src/test/java/us/eunoians/mcrpg/localization/McRPGDisplayDecimalFormatterTest.java
  • src/test/java/us/eunoians/mcrpg/setting/impl/LocaleSettingChainTest.java
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/brave-goldberg-5MElL

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Addresses testing audit finding: the holder-tracking path was only
tested with a null holder. Adds a test with a real AbilityHolder
instance to verify the non-null path.

https://claude.ai/code/session_013g1ovt1fojJgK2y5hJxzGM
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.

2 participants