fix(test): add missing @Test annotations and fix JUnit 5 lifecycle methods#38
Merged
fix(test): add missing @Test annotations and fix JUnit 5 lifecycle methods#38
Conversation
…thods - Add missing @test annotations to all test methods across 14 test files - Convert @BeforeEach/@AfterEach to @OverRide methods for setUp/tearDown to properly extend PlainTestCase base class - Fix assertEquals calls for long comparisons by adding L suffix - Apply code formatter for consistent formatting Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
This PR addresses critical test execution issues by adding missing @Test annotations and fixing JUnit 5 lifecycle method implementations across the test suite. Without proper annotations and lifecycle method patterns, test methods would not be discovered or executed by the JUnit 5 test runner.
Changes:
- Added
@Testannotations to all test methods to ensure proper test discovery and execution - Converted lifecycle methods from JUnit 5 annotations to
@Overridemethods that properly extendPlainTestCase - Fixed type mismatches in assertions by adding
Lsuffix to long literals
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| CrawlerWebProxyTest.java | Added @test annotations to 11 test methods for proxy functionality testing |
| PlaywrightClientTest.java | Added @test annotations and fixed lifecycle methods; corrected long literal comparisons |
| PlaywrightClientSslIgnoreTest.java | Added @test annotations and fixed lifecycle methods; corrected long literal comparison |
| PlaywrightClientProxyTest.java | Added @test annotations and fixed lifecycle methods; corrected long literal comparison |
| PlaywrightClientPropertyTest.java | Added @test annotations to 24 property configuration test methods |
| PlaywrightClientInternalMethodTest.java | Added @test annotations and fixed lifecycle methods for 26 internal method tests |
| PlaywrightClientHc5MigrationTest.java | Added @test annotations to 14 HC5 migration compatibility tests |
| PlaywrightClientExceptionTest.java | Added @test annotations to 16 exception handling tests; corrected long literal comparisons |
| PlaywrightClientEdgeCaseTest.java | Added @test annotations to 10 edge case tests; corrected long literal comparisons |
| PlaywrightClientDataTest.java | Added @test annotations to 24 data handling tests; corrected long literal comparisons |
| PlaywrightClientCreatorTest.java | Added @test annotations and fixed lifecycle methods for 7 creator tests |
| PlaywrightClientConfigTest.java | Added @test annotations to 16 configuration tests |
| PlaywrightClientConcurrencyTest.java | Added @test annotations to 9 concurrency tests; reformatted code |
| PlaywrightAuthTest.java | Added @test annotations and fixed lifecycle methods for 3 authentication tests |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR fixes issues with JUnit 5 test execution by adding missing
@Testannotations and correcting lifecycle method patterns across all test files.Changes Made
@Testannotations: All test methods now have proper JUnit 5@Testannotations to ensure they are discovered and executed by the test runner@BeforeEach/@AfterEachannotations to@Overridemethods forsetUp/tearDownto properly extend thePlainTestCasebase classassertEqualscalls comparinglongvalues to useLsuffix (e.g.,assertEquals(1051L, responseData.getContentLength()))mvn formatter:formatto ensure consistent code styleFiles Modified
PlaywrightAuthTest.javaPlaywrightClientConcurrencyTest.javaPlaywrightClientConfigTest.javaPlaywrightClientCreatorTest.javaPlaywrightClientDataTest.javaPlaywrightClientEdgeCaseTest.javaPlaywrightClientExceptionTest.javaPlaywrightClientHc5MigrationTest.javaPlaywrightClientInternalMethodTest.javaPlaywrightClientPropertyTest.javaPlaywrightClientProxyTest.javaPlaywrightClientSslIgnoreTest.javaPlaywrightClientTest.javaCrawlerWebProxyTest.javaTesting
mvn test🤖 Generated with Claude Code