Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SONARKT-429 Fix UTs on Windows with autocrlf true #522

Merged

Conversation

antonioaversa
Copy link
Contributor

No description provided.

@antonioaversa antonioaversa force-pushed the antonio/SONARKT-429-fix-uts-on-windows-with-autocrlf-true branch from 8b2a050 to 08c3afc Compare January 27, 2025 10:52
@@ -38,7 +39,11 @@ internal class KotlinRulesDefinitionTest {
.isEqualTo("Identical expressions should not be used on both sides of a binary operator")
Assertions.assertThat(rule.type()).isEqualTo(RuleType.BUG)
Assertions.assertThat(rule.scope()).isEqualTo(RuleScope.ALL)
Assertions.assertThat(rule.htmlDescription()).startsWith("<h2>Why is this an issue?</h2>\n<p>Using the same value on both sides")
val htmlDescription = rule.htmlDescription()?.lines();
Copy link
Contributor

@leveretka leveretka Jan 27, 2025

Choose a reason for hiding this comment

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

I think it is safe to use !! here and get rid of nullability. As we don't expect description to be null and if it is it wili fail accordingly

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indeed, I have also removed the unnecessary ;.

Copy link
Contributor

@leveretka leveretka left a comment

Choose a reason for hiding this comment

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

Looks good, have a minor suggestion to improve nullability handling

Copy link

@antonioaversa antonioaversa enabled auto-merge (squash) January 27, 2025 13:01
@antonioaversa
Copy link
Contributor Author

@leveretka I have addressed the comment.
Can you please merge? I cannot do myself, since master is locked.
Once this is merged, I will rebase the #523
Thanks

@leveretka leveretka disabled auto-merge January 27, 2025 13:14
@leveretka leveretka merged commit 69dfde9 into master Jan 28, 2025
13 checks passed
@leveretka leveretka deleted the antonio/SONARKT-429-fix-uts-on-windows-with-autocrlf-true branch January 28, 2025 09:50
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