Skip to content

feat: added operator == and expand unit test for pendingAirdropld#1293

Merged
rwalworth merged 1 commit intohiero-ledger:mainfrom
davin-core:add-operator-and-expand-unit-for-PendingAirdropId
Mar 31, 2026
Merged

feat: added operator == and expand unit test for pendingAirdropld#1293
rwalworth merged 1 commit intohiero-ledger:mainfrom
davin-core:add-operator-and-expand-unit-for-PendingAirdropId

Conversation

@davin-core
Copy link
Copy Markdown
Contributor

Description:

  • added the declaration operator == in PendingAirdropId.h
  • implement the operator ==comparing sender, reciver, FT and NFT fields in PendingAirdropId.cc
  • added new tests for NFT fromProtobuf, equality (FT/NFT), and inequality cases (different sender/receiver/token) in PendingAirdropIdUnitTests.cc:

Fixes #1267

Signed-off-by: Davin <dev.davicheanin@gmail.com>
@davin-core davin-core requested review from a team as code owners March 30, 2026 21:28
@davin-core davin-core requested a review from rwalworth March 30, 2026 21:28
@github-actions
Copy link
Copy Markdown

Hey @davin-core 👋 thanks for the PR!
I'm your friendly PR Helper Bot 🤖 and I'll be riding shotgun on this one, keeping track of your PR's status to help you get it approved and merged.

This comment updates automatically as you push changes -- think of it as your PR's live scoreboard!
Here's the latest:


PR Checks

DCO Sign-off -- All commits have valid sign-offs. Nice work!


GPG Signature -- All commits have verified GPG signatures. Locked and loaded!


Merge Conflicts -- No merge conflicts detected. Smooth sailing!


Issue Link -- Linked to #1267 (assigned to you).


🎉 All checks passed! Your PR is ready for review. Great job!

@github-actions github-actions bot added the status: needs review The pull request is ready for maintainer review label Mar 30, 2026
Copy link
Copy Markdown
Contributor

@gsstoykov gsstoykov left a comment

Choose a reason for hiding this comment

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

I know this goes out of the issue scope but shouldn't we maintain the operator for more/all data holders? @rwalworth

Copy link
Copy Markdown
Contributor

@rwalworth rwalworth left a comment

Choose a reason for hiding this comment

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

LGTM - everything looks great here, @davin-core! The operator== implementation correctly compares all four member fields, and the new tests cover the full range of cases from the issue: NFT fromProtobuf, equality for both FT and NFT, and three distinct inequality scenarios. Running workflows and will merge once they pass!

@rwalworth
Copy link
Copy Markdown
Contributor

I know this goes out of the issue scope but shouldn't we maintain the operator for more/all data holders? @rwalworth

Absolutely @gsstoykov! You're right that we should add operator== to the broader set of data holder types (info structs, transfer types, allowance types, receipt/record types, etc.). The ID types already have it, but there are quite a few value-like types that don't. I'll look to spawn a batch of issues to cover these systematically.

@rwalworth rwalworth merged commit 74e36bd into hiero-ledger:main Mar 31, 2026
11 checks passed
@rwalworth rwalworth removed the status: needs review The pull request is ready for maintainer review label Mar 31, 2026
ParasSalonia pushed a commit to ParasSalonia/hiero-sdk-cpp that referenced this pull request Apr 3, 2026
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.

[Beginner]: Add operator== and expand unit tests for PendingAirdropId

3 participants