Skip to content

fix: add pagination flags to token-pairs query #468

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

Merged
merged 4 commits into from
Aug 18, 2025
Merged

Conversation

mmsqe
Copy link
Contributor

@mmsqe mmsqe commented Aug 15, 2025

Description

for test info


Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • tackled an existing issue or discussed with a team member
  • left instructions on how to review the changes
  • targeted the main branch

@mmsqe mmsqe requested review from a team as code owners August 15, 2025 02:55
@mmsqe mmsqe marked this pull request as draft August 15, 2025 02:57
@mmsqe mmsqe marked this pull request as ready for review August 15, 2025 04:02
@aljo242
Copy link
Contributor

aljo242 commented Aug 18, 2025

@vladjdk to review - do we need to check if this logic is tested in the actual grpc query?

@vladjdk
Copy link
Member

vladjdk commented Aug 18, 2025

@aljo242 tested:

{
"1 pair registered w/pagination",
func() {
req = &types.QueryTokenPairsRequest{
Pagination: &query.PageRequest{Limit: 10, CountTotal: true},
}
pairs := testconstants.ExampleTokenPairs
pair := types.NewTokenPair(utiltx.GenerateAddress(), "coin", types.OWNER_MODULE)
s.network.App.GetErc20Keeper().SetTokenPair(ctx, pair)
pairs = append(pairs, pair)
expRes = &types.QueryTokenPairsResponse{
Pagination: &query.PageResponse{Total: uint64(len(pairs))},
TokenPairs: pairs,
}
},
true,
},

Copy link
Member

@vladjdk vladjdk left a comment

Choose a reason for hiding this comment

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

lgtm, thanks!

@vladjdk vladjdk enabled auto-merge August 18, 2025 19:47
@vladjdk vladjdk added this pull request to the merge queue Aug 18, 2025
Merged via the queue into cosmos:main with commit 7dc893d Aug 18, 2025
18 checks passed
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.

3 participants