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

chore: [IOBP-909] Adapt IDPay definitions mock API #416

Merged
merged 3 commits into from
Oct 4, 2024

Conversation

Hantex9
Copy link
Contributor

@Hantex9 Hantex9 commented Oct 4, 2024

Short description

This PR adapts the IDPay definitions API mock with the new openAPI

List of changes proposed in this pull request

  • Updated the IDPay openAPI;
  • Converted every value from precision number to cents;

src/persistence/idpay.ts Outdated Show resolved Hide resolved
@hevelius hevelius self-requested a review October 4, 2024 11:00
Copy link
Contributor

@hevelius hevelius left a comment

Choose a reason for hiding this comment

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

LGTM. Fix static checks to get a green light

Copy link

codecov bot commented Oct 4, 2024

Codecov Report

Attention: Patch coverage is 75.00000% with 1 line in your changes missing coverage. Please review.

Project coverage is 64.40%. Comparing base (b16e231) to head (9c668b7).
Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
src/payloads/features/idpay/get-timeline-detail.ts 0.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##           master     #416    +/-   ##
========================================
  Coverage   64.40%   64.40%            
========================================
  Files         167      167            
  Lines        5330     5330            
  Branches      725      718     -7     
========================================
  Hits         3433     3433            
- Misses       1759     1896   +137     
+ Partials      138        1   -137     
Files with missing lines Coverage Δ
src/persistence/idpay.ts 71.68% <100.00%> (ø)
src/routers/features/idpay/payment.ts 100.00% <ø> (ø)
src/payloads/features/idpay/get-timeline-detail.ts 77.77% <0.00%> (ø)

... and 32 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bf33788...9c668b7. Read the comment docs.

@Hantex9 Hantex9 merged commit f12261e into master Oct 4, 2024
8 checks passed
Hantex9 added a commit to pagopa/io-app that referenced this pull request Oct 4, 2024
## Short description
This PR fixes the timeline amount format considering the amount as cents

## List of changes proposed in this pull request
- Used the `formatNumberCentsToAmount` function inside the
`formatAbsNumberAmountCentsOrDefault` to format the amount from cents
into correct string.

## How to test
- The related unit tests should pass correctly
- Checkout the dev-server with this PR:
pagopa/io-dev-api-server#416
- After that enable IDPay feature flag from the profile settings
- With the dev-server started you should be able to see into
"Portafoglio" section two mocked initiatives

---------

Co-authored-by: Mario Perrotta <mario.perrotta@pagopa.it>
@Hantex9 Hantex9 deleted the IOBP-909-adapt-idpay-openapi branch October 4, 2024 11:11
LazyAfternoons pushed a commit to pagopa/io-app that referenced this pull request Oct 8, 2024
## Short description
This PR fixes the timeline amount format considering the amount as cents

## List of changes proposed in this pull request
- Used the `formatNumberCentsToAmount` function inside the
`formatAbsNumberAmountCentsOrDefault` to format the amount from cents
into correct string.

## How to test
- The related unit tests should pass correctly
- Checkout the dev-server with this PR:
pagopa/io-dev-api-server#416
- After that enable IDPay feature flag from the profile settings
- With the dev-server started you should be able to see into
"Portafoglio" section two mocked initiatives

---------

Co-authored-by: Mario Perrotta <mario.perrotta@pagopa.it>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants