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

smartcontract: introduce Convertible interface #3297

Merged
merged 3 commits into from
Jan 25, 2024
Merged

Conversation

AnnaShaleva
Copy link
Member

Close #3285. Needed for proper #3291 handling.

Copy link

codecov bot commented Jan 23, 2024

Codecov Report

Attention: 5 lines in your changes are missing coverage. Please review.

Comparison is base (ef99a7a) 85.16% compared to head (161b83f) 85.19%.

Files Patch % Lines
pkg/rpcclient/nns/record.go 0.00% 5 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3297      +/-   ##
==========================================
+ Coverage   85.16%   85.19%   +0.03%     
==========================================
  Files         327      327              
  Lines       44448    44459      +11     
==========================================
+ Hits        37854    37878      +24     
+ Misses       5095     5074      -21     
- Partials     1499     1507       +8     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@roman-khimov roman-khimov left a comment

Choose a reason for hiding this comment

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

Tests?

pkg/smartcontract/parameter.go Outdated Show resolved Hide resolved
@AliceInHunterland AliceInHunterland changed the title cmartcontract: introduce Convertible interface smartcontract: introduce Convertible interface Jan 23, 2024
Allow to pass Convertible to NewParameterFromValue. Close #3285.

Signed-off-by: Anna Shaleva <[email protected]>
Run error cases in the same loop with test cases. No functional changes.

Signed-off-by: Anna Shaleva <[email protected]>
@@ -33,6 +39,14 @@ const (
AAAA RecordType = 28
)

// ToParameter implements smartcontract.Convertible interface.
Copy link
Contributor

Choose a reason for hiding this comment

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

not ToSCParameter instead of ToParameter?

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed!

Implement smartcontract.Convertible for nns.RecordType.

Signed-off-by: Anna Shaleva <[email protected]>
@roman-khimov roman-khimov merged commit a19f85b into master Jan 25, 2024
14 of 19 checks passed
@roman-khimov roman-khimov deleted the sc-convertible branch January 25, 2024 14:16
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.

Implement smartcontract.Convertible for Actor/Invoker assistance
3 participants