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

Fix Inconsistent Usage of consts in internal/fees #1838

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

RodrigoVillar
Copy link
Contributor

@RodrigoVillar RodrigoVillar commented Dec 17, 2024

This PR does the following:

  • Fixes manager.lastConsumed() to use consts.Int64Len instead of consts.IntLen for the size of timestamp
  • Adds a table test for internal fee manager

@RodrigoVillar RodrigoVillar self-assigned this Dec 17, 2024
@RodrigoVillar RodrigoVillar linked an issue Dec 17, 2024 that may be closed by this pull request
)

func TestUnitsConsumed(t *testing.T) {
t.Run("empty manager consumes", func(t *testing.T) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can we change this to a table test instead of using t.Run in sequence? This is a bit of a non-standard pattern and I think we could make this a simple table test with an initial input, amount consumed, and expected result

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.

Fix Getter/Setter for Internal Fee Manager
2 participants