Skip to content

Improve Test DaoFactory#3469

Open
Leandroeiro wants to merge 1 commit intoiluwatar:masterfrom
Leandroeiro:dao-factory-AppTest
Open

Improve Test DaoFactory#3469
Leandroeiro wants to merge 1 commit intoiluwatar:masterfrom
Leandroeiro:dao-factory-AppTest

Conversation

@Leandroeiro
Copy link
Copy Markdown

Improve Test DaoFactory

Add edge case tests

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 1, 2026

PR Summary

Introduced edge-case unit tests for the DaoFactory App. Validates behavior when creating customers with a long ID sequence and when the input list is empty. Includes InOrder verification and additional Mockito verifications to ensure proper save/findAll interactions.

Changes

File Summary
dao-factory/src/test/java/com/iluwatar/daofactory/AppTest.java Introduced edge-case tests for App.performCreateCustomer. Added tests to verify correct save sequencing with two customers, and to ensure no saves occur when input list is empty, including InOrder verification and additional Mockito verifications.

autogenerated by presubmit.ai

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Review Summary

Commits Considered (1)
Files Processed (1)
  • dao-factory/src/test/java/com/iluwatar/daofactory/AppTest.java (2 hunks)
Actionable Comments (0)
Skipped Comments (2)
  • dao-factory/src/test/java/com/iluwatar/daofactory/AppTest.java [63-63]

    best_practice: "Unused InOrder instance; enforce call order"

  • dao-factory/src/test/java/com/iluwatar/daofactory/AppTest.java [63-69]

    best_practice: "Prefer InOrder-based verification for interaction sequence"

@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 1, 2026

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