Skip to content

Conversation

@rombirli
Copy link
Contributor

@rombirli rombirli commented Dec 17, 2025

@hashicorp-vault-sonar-prod
Copy link

hashicorp-vault-sonar-prod bot commented Dec 17, 2025

SONARJAVA-4960

@rombirli rombirli force-pushed the rombirli/S1854-false-positive branch from 19d09dc to 947f918 Compare December 18, 2025 08:39
@rombirli rombirli marked this pull request as ready for review December 19, 2025 13:41
@github-actions
Copy link
Contributor

This PR is stale because it has been open 7 days with no activity. If there is no activity in the next 7 days it will be closed automatically

@github-actions github-actions bot added the stale label Dec 27, 2025
@github-actions github-actions bot closed this Jan 4, 2026
@rombirli rombirli reopened this Jan 5, 2026
@rombirli rombirli requested a review from a team January 5, 2026 07:40
@github-actions github-actions bot removed the stale label Jan 6, 2026
@sonarqube-next
Copy link

sonarqube-next bot commented Jan 8, 2026

@github-actions
Copy link
Contributor

This PR is stale because it has been open 7 days with no activity. If there is no activity in the next 7 days it will be closed automatically

@rombirli rombirli force-pushed the rombirli/S1854-false-positive branch from eb0e8ef to b23c2de Compare January 22, 2026 07:03
@rombirli
Copy link
Contributor Author

Addressed both issues in d78ed6b

@sonarqube-next
Copy link

@github-actions
Copy link
Contributor

This PR is stale because it has been open 7 days with no activity. If there is no activity in the next 7 days it will be closed automatically

@github-actions github-actions bot added the stale label Jan 30, 2026
@tomasz-tylenda-sonarsource
Copy link
Contributor

Is this ready for re-review?

@github-actions github-actions bot removed the stale label Jan 31, 2026
@rombirli
Copy link
Contributor Author

rombirli commented Feb 2, 2026

Is this ready for re-review?

Yes it is

Copy link
Contributor

Choose a reason for hiding this comment

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

Let's use dogfooding on peachee to test this PR. If you haven't used it before, it's a good thing to learn. We can talk about it offline.

assertThat(unknownSymbol.isTypeSymbol()).isFalse();
assertThat(unknownSymbol.isVariableSymbol()).isFalse();
assertThat(unknownSymbol.isMethodSymbol()).isFalse();
assertThat(unknownSymbol.isMethodSymbol()).isEqualTo(unknownSymbol instanceof Symbols.UnknownMethodSymbol);
Copy link
Contributor

Choose a reason for hiding this comment

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

We should not have logic in tests. Each test that calls assertCommonProperties should have an assertion with a constant, either true or false. After all, if this property changes, it is not a common property.

Reference: https://testing.googleblog.com/2014/07/testing-on-toilet-dont-put-logic-in.html

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