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

Apply assorted test cleanup #562

Merged
merged 1 commit into from
Apr 13, 2023
Merged

Conversation

Stephan202
Copy link
Member

@Stephan202 Stephan202 commented Apr 2, 2023

Suggested commit message:

Apply assorted test cleanup (#562)

Summary of changes:
- Inline more `CompilationTestHelper` fields.
- Move inner class to the bottom of the outer class.
- Improve test parameter name.

@Stephan202 Stephan202 added this to the 0.10.0 milestone Apr 2, 2023
@github-actions
Copy link

github-actions bot commented Apr 2, 2023

Looks good. No mutations were possible for these changes.
Mutation testing report by Pitest. Review any surviving mutants by inspecting the line comments under Files changed.

Copy link
Member Author

@Stephan202 Stephan202 left a comment

Choose a reason for hiding this comment

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

I had eye-balled these for some time now; finally decided to flush them.

Comment on lines -13 to -14
private final CompilationTestHelper compilationTestHelper =
CompilationTestHelper.newInstance(RedundantStringConversion.class, getClass());
Copy link
Member Author

Choose a reason for hiding this comment

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

I think that initially we decided against this, but it is more consistent this way (and it may help simplify the generalizations we're discussing in #494).

Comment on lines -21 to -22
private final CompilationTestHelper compilationTestHelper =
CompilationTestHelper.newInstance(TestChecker.class, getClass());
Copy link
Member Author

Choose a reason for hiding this comment

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

There's also a BugCheckerRefactoringTestHelper field in SourceCodeTest, but that's part of #561.

@rickie rickie requested review from rickie and oxkitsune April 6, 2023 07:31
Copy link
Member

@rickie rickie left a comment

Choose a reason for hiding this comment

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

Nice. I agree, it's fine to always inline them.

Summary of changes:
- Inline more `CompilationTestHelper` fields.
- Move inner class to the bottom of the outer class.
- Improve test parameter name.
@rickie rickie force-pushed the sschroevers/assorted-test-improvements branch from 221f1d3 to 6498ced Compare April 13, 2023 10:42
@rickie
Copy link
Member

rickie commented Apr 13, 2023

Rebased, will merge once 🟢.

@github-actions
Copy link

Looks good. No mutations were possible for these changes.
Mutation testing report by Pitest. Review any surviving mutants by inspecting the line comments under Files changed.

@rickie rickie merged commit 94ffc5d into master Apr 13, 2023
@rickie rickie deleted the sschroevers/assorted-test-improvements branch April 13, 2023 10:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

None yet

3 participants