Add unit tests for SDK v3 client and transaction packages#2
Merged
kyonRay merged 5 commits intorelease-3.9.0from Nov 4, 2025
Merged
Add unit tests for SDK v3 client and transaction packages#2kyonRay merged 5 commits intorelease-3.9.0from
kyonRay merged 5 commits intorelease-3.9.0from
Conversation
Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>
…classes Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>
Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>
Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add unit tests to increase coverage for FISCO BCOS SDK v3
Add unit tests for SDK v3 client and transaction packages
Nov 4, 2025
kyonRay
approved these changes
Nov 4, 2025
kyonRay
added a commit
that referenced
this pull request
Nov 13, 2025
…S#945) * <fix>(build): update dependencies version, add UT with AI. * Add unit tests to increase JaCoCo coverage from 30.1% to 30.7% (#1) * Initial plan * Initial setup: Upgrade Gradle to 7.6.4 for Java 17 compatibility and fix duplicate resources handling Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Add unit tests for model classes and exceptions to improve coverage Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Add more unit tests for model and enum classes to increase coverage Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Add unit tests for crypto exception classes to increase coverage Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Downgrade Gradle version to 6.3 --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Add unit tests for SDK v3 client and transaction packages (#2) * Initial plan * Add unit tests for client and transaction packages - part 1 Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Add more unit tests for client protocol response and transaction dto classes Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Add unit tests for LogFilterRequest, model BO classes and CommonConstant Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Fix ResultCodeEnumTest to avoid mutating enum state in tests Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * <fix>(test): fixed tests path. * Add comprehensive test coverage for uncovered utility, protocol, and codec classes (#4) * Initial plan * Add comprehensive tests for ByteUtils, ThreadPoolService, SystemInformation, SecureRandomUtils, and LinuxSecureRandom Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Add comprehensive tests for JsonRpcRequest and TopicTools Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * Address code review feedback - fix resource cleanup and remove redundant tests Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: kyonRay <32325790+kyonRay@users.noreply.github.com> * <fix>(CI): fix windows ci version to 2025. * <fix>(build): update publish url to central.sonatype. --------- Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
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.
Increases test coverage for
org.fisco.bcos.sdk.v3.clientandorg.fisco.bcos.sdk.v3.transactionpackages. The project uses JDK 8 and Jacoco for coverage measurement.Changes
Client Package (10 test classes)
DefaultBlockParameter*,LogFilterRequest,BlockNumber,BlockHash,PendingTxSizeGroupStatus,TransactionAttributeClientExceptionTransaction Package (15 test classes)
TransactionException,JsonException,ContractExceptionCommonResponse,CallResponse,CallRequest,ResultCodeEnumCommonConstant,AbiInfo,BinInfoEIP1559Struct,DefaultGasProvider,StaticGasProviderConvert(Wei/Ether conversion),JsonUtilsCoverage Focus
Tests cover constructors, accessors, equals/hashCode, edge cases (null, empty, boundary values), and business logic:
All tests use existing infrastructure (JUnit 4, Mockito 4.8.0) and maintain JDK 8 compatibility.
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.